L* R*
HOME FORUM DOWNLOADS
Content
  Links
     Browse SVN
     SVN Commit log
     Documentation (Wiki)
  Developers
     Taskmanager
User
Welcome, Guest. Please login or register.
Did you miss your activation email?
November 21, 2008, 08:50:28 PM

Login with username, password and session length
Search



Advanced search
Support GoPHP5.org
BeBot - An Anarchy Online/Age Of Conan chat automaton > Forum > Modules > Modules for older versions > 0.2.x Custom/Unofficial Modules > Topic: Guild Depot
Pages: [1] 2 3 4   Go Down
« previous next »
Print
Author Topic: Guild Depot  (Read 4493 times)
0 Members and 1 Guest are viewing this topic.
Naturalistic
BeBot Contributor
Experienced
*******
Offline Offline

Posts: 221


Guild Depot
« on: July 06, 2006, 12:14:46 AM »

Finally got around to finishing it/uploading it.

Featured: It's like a bank, you add your items that are open for the org to have/borrow. People can search for specific items, be able to see who owns the current item, and be able to ask for it.

Suggestions or think of stuff to add? Lemme know. Hope you enjoy it =)



**NOTE**
This only works on the Department style guild ranking system. I haven't been able to figure out a universal code to match all org rankings. It's fairly simple to fix to match it to your org. Or just remove it altogether. Your choice Smiley

Once I make changes and updates according to guilds, I'll update this. Still working-progress.
Logged

220/25 Eternalist Doctor
-----------------------------
Campalot Coding Co-ordinator and Super Admin
http://www.campalot.info/index.php
Pharexys
Apprentice
***
Offline Offline

Posts: 94


Re: Guild Depot
« Reply #1 on: July 06, 2006, 12:55:59 PM »

Sounds very nice Grin i'll post if i see anything wrong.
Logged
Glarawyn
BeBot Developer
Champion
********
Offline Offline

Posts: 414



Re: Guild Depot
« Reply #2 on: July 06, 2006, 03:39:46 PM »

If you go by rank_id instead of rank, you have two assurances:

rank 0 = Org Leader (President, Lord, whatever...)
rank 1 = 2nd in command (General, whatever.)

However rank 1 can't always do much. See below. Smiley

Department
0=President
1=General
2=Squad Commander
3=Unit Commander
4=Unit Leader
5=Unit Member
6=Applicant

In a Department, the rank Unit Commander and higher allows organization members to recruit new members.

Faction
0=Director
1=Board Member
2=Executive
3=Member
4=Applicant

In a Faction, only the Director and Board Members can invite new members.

Republic
0=President
1=Advisor
2=Veteran
3=Member
4=Aplicant

In a Republic only the President and Advisors can invite new members.

Monarchy
0=Monarch
1=Counsil
2=Follower

In a monarchy, only the Monarch can invite new members.

Anarchism
0=Anarchist

An anarchism has 1 leader who is also an "Anarchist" but only this member gets to chose the governing form. It takes 3 members who do /org kick {name} to kick someone from such an org. Everyone in an anarchism can recruit new members.

Feudalism
0=Lord
1=Knight
2=Vassal
3=Peasant

In a feudalism, only the Lord can invite new members.
Logged
Naturalistic
BeBot Contributor
Experienced
*******
Offline Offline

Posts: 221


Re: Guild Depot
« Reply #3 on: July 06, 2006, 08:47:06 PM »

Yes, I know the ranks Tongue

The problem was figuring out a universal "rank" code.

Members shouldn't be allowed to remove other members, but a General/pres should be.

Logged

220/25 Eternalist Doctor
-----------------------------
Campalot Coding Co-ordinator and Super Admin
http://www.campalot.info/index.php
Zimble
Freshman
*
Offline Offline

Posts: 7


Re: Guild Depot
« Reply #4 on: August 09, 2006, 10:00:09 AM »

Nice mod, Naturalistic
Already wrote a web interface for that.

But while trying to delete items we noticed that members are not able to delete items from the db.

I took a look at the code and noticed that in line 111 in the depot_del function the calling charname is compared with the itemurl stored in the db, instead of the contributorID.
So only admins were able to delete items.

So I increased the index by one:
Code:
111c111
<             if($result2[0][2]==$name) $candel = true;
---
 >             if($result2[0][3]==$name) $candel = true;


Maybe its just our database and the fields are in a diffrent order but I wanted you to know...
Logged

Zimble/RK3
Naturalistic
BeBot Contributor
Experienced
*******
Offline Offline

Posts: 221


Re: Guild Depot
« Reply #5 on: August 09, 2006, 10:26:11 AM »

Which version of the bot do you run?

It's working as it should here...I'll take a look into it though.
Logged

220/25 Eternalist Doctor
-----------------------------
Campalot Coding Co-ordinator and Super Admin
http://www.campalot.info/index.php
Zimble
Freshman
*
Offline Offline

Posts: 7


Re: Guild Depot
« Reply #6 on: August 09, 2006, 12:01:46 PM »

Thx for the quick response

main.php says $bot_version = "0.3.3";

Don't know, where "our" depot.php is coming from, since I'm not the hoster of the bot

But from what I've seen in depot.php
Code:
$db -> query("CREATE TABLE IF NOT EXISTS depot
              (id INT(11) NOT NULL PRIMARY KEY, itemName VARCHAR(255), itemURL VARCHAR(255), contributorID VARCHAR(30))");

than $result(0)(2) is indeed the itemURL.
Logged

Zimble/RK3
Naturalistic
BeBot Contributor
Experienced
*******
Offline Offline

Posts: 221


Re: Guild Depot
« Reply #7 on: August 13, 2006, 11:23:01 AM »

Ah... I added the DB info afterwards.

I probably put them into the wrong order. I'll fix it up, thanks for pointing that out =)
Logged

220/25 Eternalist Doctor
-----------------------------
Campalot Coding Co-ordinator and Super Admin
http://www.campalot.info/index.php
Malosar
Expert
*****
Offline Offline

Posts: 259


WWW
Re: Guild Depot
« Reply #8 on: August 18, 2006, 05:59:46 PM »

Handy module but didn't quite do what I'd like so I modified it a bit. Now you can add an item and include a number after it depending on how many you have. Adding 63 of the same item and same ql just seemed ridiculous so you can do !depot add itemref 63. The list will display itemref X63.

Also adding no number just adds 1 to the amount since it's obviously just 1 item.

edit: Removed file as was old version.
« Last Edit: February 05, 2007, 01:25:10 PM by Malosar » Logged

Eternalist
General of The Syndicate
Naturalistic
BeBot Contributor
Experienced
*******
Offline Offline

Posts: 221


Re: Guild Depot
« Reply #9 on: August 19, 2006, 12:03:10 AM »

Ah, yeah... forgot to add my updated version.

Has the option to choose what org type you are and the 'rank' you want to be able to remove items.

And if there's multiple of the same item but different people, it x# the item, and lists who has it.

Just need to write a post-it for me to remember to upload tomorrow Smiley
Logged

220/25 Eternalist Doctor
-----------------------------
Campalot Coding Co-ordinator and Super Admin
http://www.campalot.info/index.php
Malosar
Expert
*****
Offline Offline

Posts: 259


WWW
Re: Guild Depot
« Reply #10 on: August 19, 2006, 08:33:13 AM »

Very nice, I'll check it out Smiley
Logged

Eternalist
General of The Syndicate
Zimble
Freshman
*
Offline Offline

Posts: 7


Re: Guild Depot
« Reply #11 on: August 19, 2006, 01:41:16 PM »

Maybe you should add an item-remove link in list/search view to make it easier to remove items:

Code:
<?php
$stritem 
.= "<font color=#ffff66>#" . $val[0] . "</font> - <a href=" . $val[2] . ">". $val[1] ."</a>\n[Item holder: " . $val[3] . "] [ <a href='chatcmd:///tell <botname> depot del " . $val[0] . "'>Remove</a> ]\n\n";
?>


So you no longer need to copy&paste the itemid of the item you want to delete
Logged

Zimble/RK3
jjones666
BeBot Contributor
Champion
*******
Offline Offline

Posts: 353


Re: Guild Depot
« Reply #12 on: August 20, 2006, 06:38:09 AM »

*pokes naturalistic*
Logged
Wolfbiter
BeBot Contributor
Apprentice
*******
Offline Offline

Posts: 141



WWW
Re: Guild Depot
« Reply #13 on: August 20, 2006, 04:22:07 PM »

No poking of natu without my written expression!
Logged

220 Doctor | 220 Adventurer | 220 Shade
jjones666
BeBot Contributor
Champion
*******
Offline Offline

Posts: 353


Re: Guild Depot
« Reply #14 on: August 24, 2006, 05:38:50 PM »

Would be cool to show the QL in the list also, tried to figure it out but too tired Smiley

-jj-
Logged
Pages: [1] 2 3 4   Go Up
Print
BeBot - An Anarchy Online/Age Of Conan chat automaton > Forum > Modules > Modules for older versions > 0.2.x Custom/Unofficial Modules > Topic: Guild Depot
« previous next »
 
Jump to:  

Recent
Change text in remember "...
by gerborg
[Today at 05:14:57 PM]

Log playtime from buddys ...
by Temar
[November 20, 2008, 10:33:57 AM]

Vote Core module and Simp...
by Temar
[November 19, 2008, 09:26:52 AM]

Restrict access for one m...
by Organizer
[November 19, 2008, 03:21:19 AM]

Custom / Revised Modules ...
by Elesar1
[November 17, 2008, 03:51:46 PM]

TWC
by Temar
[November 16, 2008, 11:39:12 AM]

Are there any FUN modules...
by Elesar1
[November 15, 2008, 07:39:15 PM]

Call to a member function...
by exxie
[November 15, 2008, 09:29:31 AM]

Ported Modules
by Alreadythere
[November 14, 2008, 06:10:07 PM]

cURL and other non-defaul...
by Temar
[November 14, 2008, 04:11:44 PM]
Stats
Members
Total Members: 1235
Latest: DDDepressionnn
Stats
Total Posts: 11037
Total Topics: 1496
Online Today: 16
Online Ever: 168
(July 01, 2007, 09:30:02 PM)
Users Online
Users: 0
Guests: 21
Total: 21

Powered by SMF 1.1.7 | SMF © 2006-2008, Simple Machines LLC
TinyPortal v0.9.8 © Bloc | NewDef design by Bloc
Page created in 0.389 seconds with 30 queries. (Pretty URLs adds 0.03s, 4q)
Loading...