PtokaX forum

Archive => Archived 5.1 boards => Finished Scripts => Topic started by: blastbeat on 08 May, 2007, 23:17:44

Title: bash bot v0.1 lua 5
Post by: blastbeat on 08 May, 2007, 23:17:44
Hi

i wrote a script which sends random quotes of www.bash.org (or www.german-bash.org) in main chat or simple extra chatroom.
the quotes are stored in a database created by extra scripts which can parse the html code.

thanks for comments, blastbeat


--[[

bash bot v0.3 lua 5 by blastbeat

- this script sends quotes from a database in mainchat or extra chatroom
- its possible to set time intervals for sending
- user can enter or leave chatroom with rightclick

- changelog:
- to v0.1 (release: 08.05.2007):
- [bug] roomtimercmd instead of roomtimer (thanks to baba.runner)
- "<>" filtered from quotes
- function "ParseHTML" replaces with the table "toparse" more special characters
- ascii below the quotes can be changed in settings
- the whole quote database will not be loaded in memory any more
- to v0.2 (release: 10.05.2007):
- [bug] postfix instead of nickName (thanks to baba.runner)
- list of users in chatroom saved in extra file

- release: 12.05.2007

]]--
Title: Re: bash bot v0.1 lua 5
Post by: CrazyGuy on 09 May, 2007, 16:17:03
nice  :)
Title: Re: bash bot v0.1 lua 5
Post by: baba.runner on 10 May, 2007, 01:08:35
Hi Blastbeat

nice script.

One little error in the function to set the timer for the chatroom
in row 221 of the bash_de.lua of the GermanBash script
change
elseif cmd==roomtimer and masterPerm[GetUserProfile(user.sName)]==1 then

to

elseif cmd==roomtimercmd and masterPerm[GetUserProfile(user.sName)]==1 then

Regards. ;)
Title: Re: bash bot v0.1 lua 5
Post by: blastbeat on 12 May, 2007, 00:55:46
Hi baba.runner

thanks for finding this bug. i updated the script to version v0.2
update to v0.3, change of timer should work now
update to v0.4