collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
* Search

* Board Stats
  • stats Total Members: 989
  • stats Total Posts: 18366
  • stats Total Topics: 2501
  • stats Total Categories: 7
  • stats Total Boards: 35
  • stats Most Online: 1144

Author Topic: Guild Depot  (Read 55629 times)

0 Members and 1 Guest are viewing this topic.

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #30 on: February 06, 2007, 04:43:19 pm »
Quick minor chage, limited output on depot list to 50 items in guild chat and no limit in a tell. Reposted depot.php in previous post.
Eternalist
General of The Syndicate

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #31 on: February 09, 2007, 04:43:34 pm »
Last change for this hopefully, at least for my usability requirements. I've added a quantity add function so if I'm adding items identical to ones already in the depot, I just need to raise the amount instead of adding as a separate item. Links in list and search now have [+] [-] instead of [remove] to allow quick control of inventory quantities.

Another minor change, it won't spam the depot list if you get a command wrong anymore. The list will only be displayed on !depot list instead of just !depot as org members would get a command wrong in a tell and wait for 16 pages of items.

EDIT: Removed these versions for download as they are outdated. See newer post further on in thread.
« Last Edit: March 12, 2007, 02:04:19 pm by Malosar »
Eternalist
General of The Syndicate

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #32 on: February 09, 2007, 07:13:37 pm »
And lastly here is my depot uploading script I wrote which creates a very basic html table of your depot items, including auno links, and uploads it to a webserver via FTP. So useful for those whom run a website and want the depot on there as well. You can incorporate it into your site, or spruce it up however you like. I run the script via a cron once a day.

EDIT: Removed file for download as older version, see post further on in thread.
« Last Edit: March 12, 2007, 02:04:44 pm by Malosar »
Eternalist
General of The Syndicate

Offline pusikas

  • BeBot Apprentice
  • ***
  • Posts: 161
  • Karma: +0/-0
Re: Guild Depot
« Reply #33 on: February 10, 2007, 01:57:45 pm »
For some reason, the
Code: [Select]
if (is_writable($filename)) {is always false for me, so the script always complains about not being able to write the file. If I comment this out, the HTML file gets created and uploaded as it should. *shrug* So it kinda works for me, except for that strange glitch. Thanks for a nice addition to he depot. :)
Luuv  Bot-Keeper of Vengeance ^^*

Offline Dabaron

  • BeBot Apprentice
  • ***
  • Posts: 163
  • Karma: +0/-0
Re: Guild Depot
« Reply #34 on: February 12, 2007, 11:39:23 am »
Last change for this hopefully, at least for my usability requirements. I've added a quantity add function so if I'm adding items identical to ones already in the depot, I just need to raise the amount instead of adding as a separate item. Links in list and search now have
  • [-] instead of [remove] to allow quick control of inventory quantities.


Another minor change, it won't spam the depot list if you get a command wrong anymore. The list will only be displayed on !depot list instead of just !depot as org members would get a command wrong in a tell and wait for 16 pages of items.

There is an error with your syntax for the - in the blob.... still trying to figure out exactly what it is but it keeps killing bot with what it says is an error on line 160.

Offline redmagician

  • BeBot Rookie
  • *
  • Posts: 13
  • Karma: +0/-0
Re: Guild Depot
« Reply #35 on: February 13, 2007, 05:49:00 am »
Very nice module.

One of my org-mates is a help-a-holic so she went crazy when I dropped this into the bot. *looks at over 3000 entries just from her in the past day or so*

I've run into a few 'problems' though

1) On the uploading script is_writable checks to see if the file is writable *and* if it exists so it pretty much always errors if the module is run for the first time

I see two solutions to this, either mention it somewhere so the person running the bot can create an empty file with the filename

OR write the file anyway if it doesn't exist (maybe by using file_exists somewhere in there?)

2) Theres also a problem with the way the ql is extracted. Its assumed the ql starts at character 24 but this isn't always true, theres a few that start at 22 (nanos and belts from what she's told me, she's literally crazy about the module...)

I'm not quite sure what I'll do to fix this on my end, I'll probably check the previous few characters for a '/' and start on the character right after.

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #36 on: February 13, 2007, 03:28:02 pm »
Fixed parsing of ql to use an exploded array of the itemref instead of counting characters. Also fixed an incorrect response for gc on adding item with quantity. Removed is_writable check on depotftp.php and added more feedback on processes in case of errors.

Previous post files updated.
Eternalist
General of The Syndicate

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #37 on: March 08, 2007, 05:02:54 pm »
Updated Depot again. Added private bank functions to allow personal banks that cannot be searched or accessed by anyone but you and your alts. The module will search any items on any of your alts listed in the db and allow control from any character on your alts list as well. Also updated control on your own items in the public org bank to allow from any of your listed alts.

Commands are now split (mostly) between !depot (public org bank) and !bank (private bank only).

Also added a request function, with link in the blob for easy request access. Clicking the link has the bot send a tell to the item holder advising the name, itemname and id.

Updated depotftp.php to retrieve public only items for ftp'ing.

Existing depot users will need to update their sql table:
Code: [Select]
update depot add column private boolean;

Update: Fixed a couple of issues as stated further on in thread
« Last Edit: March 12, 2007, 10:52:58 pm by Malosar »
Eternalist
General of The Syndicate

Offline Ozball

  • BeBot Rookie
  • *
  • Posts: 15
  • Karma: +0/-0
Re: Guild Depot
« Reply #38 on: March 10, 2007, 06:51:38 am »
Not sure if its somthing I'm doing wrong or what, but having a couple issues with the module.

1. After doing !depot list it displays the output fine, but then displays a second line saying "/tell Tvbot !help !depot/bank"
eg.
To [Tvbot]: !depot list
[Tvbot]: Item List
[Tvbot]: /tell Tvbot !help !depot/bank

2. When doing !depot add <item> without a number after it I get the following in the console.

"Warning: Missing argument 4 for depot::depot_add(). called in <path>\Depot.php on line 57 and defined in <path>\Depot.php on line 126
MySQL error (# 0) on query: INSERT INTO depot (id, itemName, itemURL, ql, amount, contributorID, private) VALES ('1173505348', 'Flurry of Blows', 'itemref://85907/85908/27', '27', '1', 'Sidus',)
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1"

and then the item doesnt add to the list (even though the bot out puts that it has been added, !depot list doesnt show it).

One final question ^^ with the depotftp are we ment to open the file and manually put in the dbname, dbpass etc?

Other than that, awesome module :D
« Last Edit: March 10, 2007, 07:07:27 am by Ozball »
Slynthia - General and Botmaster of Terminal Velocity - RK1

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #39 on: March 10, 2007, 03:27:03 pm »
hmm guess my testing wasn't as thorough as I thought, seemed to be working fine. I'll check it out over the weekend and see if I can track down the problems.

First thing though is "VALES" should be "VALUES", not sure how that could have changed. It's also not adding the private setting there.

Also, yes you are supposed to edit the depotftp.php and enter all the values for the db, ftp etc.
Eternalist
General of The Syndicate

Offline Ozball

  • BeBot Rookie
  • *
  • Posts: 15
  • Karma: +0/-0
Re: Guild Depot
« Reply #40 on: March 10, 2007, 04:18:06 pm »
The VALES is my typo sorry. It is VALUES.
Slynthia - General and Botmaster of Terminal Velocity - RK1

Offline Ozball

  • BeBot Rookie
  • *
  • Posts: 15
  • Karma: +0/-0
Re: Guild Depot
« Reply #41 on: March 11, 2007, 07:27:55 am »
Been playing with trying to get depotftp working, and keep running into a problem with, I think, the way im putting in the ftp server.

At the moment what I have is:

$ftpserver="ftp://ftp.terminalvelocity-ao.com/";

and I get:

[11-Mar-2007 16:52:58] PHP Warning:  ftp_connect(): php_network_getaddresses: getaddrinfo failed: No such host is known.  in F:\Tvbot\BeBot_v0.2.11\modules\depotftp.php on line 60
[11-Mar-2007 16:52:58] PHP Warning:  ftp_login() expects parameter 1 to be resource, boolean given in F:\Tvbot\BeBot_v0.2.11\modules\depotftp.php on line 62

I'm assuming the second warning is due to the first one, but the first one I cant seem to avoid. I've tried numorus ways of putting the ftp server, without the ftp://, with http:// instead of the ftp:// even tried with the username and password in the path and nothing seems to work. Any idea what I'm doing wrong?  :-\
Slynthia - General and Botmaster of Terminal Velocity - RK1

Offline Vhab

  • Contributor
  • *******
  • Posts: 180
  • Karma: +0/-0
    • VhaBot Forum
Re: Guild Depot
« Reply #42 on: March 11, 2007, 09:41:36 am »
should be without ftp:// and / afaik.
double-checked the domain name?

Offline Ozball

  • BeBot Rookie
  • *
  • Posts: 15
  • Karma: +0/-0
Re: Guild Depot
« Reply #43 on: March 11, 2007, 02:36:45 pm »
O.o I could have sworn I tried that.... maybe I had the / at the end before or somthing.... Works now though thanks :)
Slynthia - General and Botmaster of Terminal Velocity - RK1

Offline Malosar

  • BeBot Expert
  • ****
  • Posts: 259
  • Karma: +0/-0
    • http://www.lowerdimension.com
Re: Guild Depot
« Reply #44 on: March 12, 2007, 02:01:33 pm »
Fixed errors on depot add, had missed a private setting on one of the depot add function calls. Fixed the selection for main/alts items and owner checks.

Updated previous post with newer Depot.php
Eternalist
General of The Syndicate

 

* Recent Posts
Com bot module by bitnykk
[November 25, 2024, 05:36:11 pm ]


0.8.x updates for AO by bitnykk
[June 23, 2024, 03:19:47 pm ]


0.8.x updates for AoC by bitnykk
[June 23, 2024, 03:19:44 pm ]


[AoC] special char for items module by bitnykk
[February 09, 2024, 09:41:18 pm ]


BeBot still alive & kicking ! by bitnykk
[December 17, 2023, 12:58:44 am ]

* Who's Online
  • Dot Guests: 106
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.
* Forum Staff
bitnykk admin bitnykk
Administrator
Khalem admin Khalem
Administrator
WeZoN gmod WeZoN
Global Moderator
SimplePortal 2.3.7 © 2008-2024, SimplePortal