StealthBot.net: Clan Rank Script (crs) - StealthBot.net

Jump to content

  • (9 Pages)
  • +
  • 1
  • 2
  • 3
  • 4
  • 5
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic

Clan Rank Script (crs)

#51 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 06:31 PM

Yeah, now it works because you reloaded the script since before it didn't even say, "Rank: "

What's odd is how is rank variable returning the lower-case username of the person joining when it's initially set to return a number and no piece of code changes the rank value to anything other than a number? What's even odder is how it's not erroring for me when I use this to greet members and non-members alike.

How many MemberData.mdb files do you have in your bot folder? Did you allow this script to create a new database or are you using the old one? The reason I ask this is because the old, plugin database had the ID field acting as a counter in the first column (rs.Fields(0)), resulting in the username of the person to be in column 2 (rs.Fields(2)) ...odd how this "rank" variable is returning the username of the person when the username is stored in column 1 (rs.Fields(0)), instead of column 1 (rs.Fields(0)), and the rank is now in column 2 (rs.Fields(1)) ...

#52 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 06:45 PM

I let the plugin create the database itself, but I manually went in to it and added everyone from my old one with their ranks and stuff, easier then doing it through cmds.. and i guess it created the ID colum automatically, so i went in and deleted it, now the greet works.. 2 questions now...
1. for the Rank-Specific greets in the scripts.ini file, do i do it like this: <rank name>=<greet> (EX: Overlord of Flame=%0, an %r, has entered the channel with a ping of %pms.)

2. I am unable to set a members rank by saying the ranks name, I have to use the number..

Quote

[10:41:53 AM] <Spiritless_One> .crsset legion_of_flame bot
[10:41:53 AM] Scripting runtime error '-2147217904' in crs: (line 1481; column 0)
[10:41:53 AM] [Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1.
[10:41:53 AM] Offending line: >>
[10:41:53 AM] Scripting runtime error '-2147217904' in crs: (line 1481; column 0)
[10:41:53 AM] [Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1.
[10:41:53 AM] Offending line: >>
[10:41:53 AM] Scripting runtime error '-2147217904' in crs: (line 1481; column 0)
[10:41:53 AM] [Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1.
[10:41:53 AM] Offending line: >>
[10:42:09 AM] <Spiritless_One> .crsset legion_of_flame 22
[10:42:10 AM] <Spiritless_LoF> " legion_of_flame " has had their rank changed to rank 22 - Bot

This post has been edited by Spiritless: November 03, 2009 - 06:50 PM

Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#53 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 06:58 PM

Quote

I let the plugin create the database itself, but I manually went in to it and added everyone from my old one with their ranks and stuff, easier then doing it through cmds.. and i guess it created the ID colum automatically, so i went in and deleted it, now the greet works.. 2 questions now...
You need to stop editing the database yourself. Right now; there isn't a need to remove the ID column because it wasn't added in the first place. If you can't add your members manually, don't do it because obviously you're doing it wrong; there is no way in hell this script created the ID column automatically because I didn't code it to create the column, so please stop lying to me and saying you manually deleted it because if you let the script create the database on its own, you would've noticed there is no ID column. I know you're a scripter, so look at the code where it creates the database and see for yourself if you don't believe me.

Quote

1. for the Rank-Specific greets in the scripts.ini file, do i do it like this: <rank name>=<greet> (EX: Overlord of Flame=%0, an %r, has entered the channel with a ping of %pms.)
<rank number>=<greet>

Quote

2. I am unable to set a members rank by saying the ranks name, I have to use the number..
I'll fix this now, thanks.

#54 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 07:07 PM

View PostThe-Black-Ninja, on 03 November 2009 - 10:58 AM, said:

You need to stop editing the database yourself. Right now; there isn't a need to remove the ID column because it wasn't added in the first place. If you can't add your members manually, don't do it because obviously you're doing it wrong; there is no way in hell this script created the ID column automatically because I didn't code it to create the column, so please stop lying to me and saying you manually deleted it because if you let the script create the database on its own, you would've noticed there is no ID column. I know you're a scripter, so look at the code where it creates the database and see for yourself if you don't believe me.

I already did take a look at the script, and I know it's not coded to write an ID column, but it was there, I'm guessing sometime while I was working on the database I accidently replaced the old one with the new one it created or something, but it's fine now, I double checked all the column names and order between the database i'm using and a newly created one from the script and it matches now. Sorry >,,< (yes, vampire face. ^,..,^)
Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#55 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 07:30 PM

Updated. I also fixed a minor issue when using apostrophe's in your reasons.

#56 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 09:44 PM

I can't get the rank-specific greets to work.. this is the format I used for each rank number:

1=%0, an %r - Leader, has entered the channel with a ping of %pms.



It should display in the channel as:

Quote

<Spiritless_LoF Spiritless_One, an Overlord of Flame - Leader, has entered the channel with a ping of 32ms.>

But it displays this instead:

Quote

<Spiritless_LoF >

I made the m_greet= line blank, and left the member greet on, like this:
'//  Member greet enabled?
m_greet_on=True
'//  Member greet message.
m_greet=



/me feels like a total noob now. :/
Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#57 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 09:50 PM

So you did exactly what the instructions told you not to do; making that line totally blank...good job. Maybe you should read the FAQs before you edit anything else.

#58 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 10:00 PM

I'm sorry, the FAQ says "After you've added the greet, the greet will be stored in the scripts.ini file, found in the Stealthbot/scripts folder, under the " [crs] " section. You can also edit the greets manually here as well, provided that you DO NOT REMOVE the " m_greet " or the " nm_greet " lines."
It says nothing about leaving the greet message on the line m_greet= And if I put something on that line, it says that greet, instead of the rank-specific greet. So don't think I havent read the FAQ.

'//  Member greet display type; 1 - all chat, 2 - emote, 3 - whisper
m_greet_dsp=2
'//  Non-member greet display type; 1 - all chat, 2 - emote, 3 - whisper
nm_greet_dsp=3
'//  Member greet enabled?
m_greet_on=True
'//  Non-member greet enabled?
nm_greet_on=True
'//  Member greet message.
m_greet=
'//  Non-member greet message.
nm_greet=Welcome %0 to %c. Your ping is %p. To join, just type .apply


Quote

[01:56:43 PM] -- Spiritless_One [32ms] has joined the channel using WarCraft III: The Frozen Throne (Level: 2, icon tier Undead, peon icon, in clan LoF) and acquired ops.
[01:56:43 PM] Rank: 1
[01:56:44 PM] <Spiritless_LoF >



'//  Member greet display type; 1 - all chat, 2 - emote, 3 - whisper
m_greet_dsp=2
'//  Non-member greet display type; 1 - all chat, 2 - emote, 3 - whisper
nm_greet_dsp=3
'//  Member greet enabled?
m_greet_on=True
'//  Non-member greet enabled?
nm_greet_on=True
'//  Member greet message.
m_greet=Hi %0.
'//  Non-member greet message.
nm_greet=Welcome %0 to %c. Your ping is %p. To join, just type .apply

Quote

[01:57:30 PM] -- Spiritless_One [32ms] has joined the channel using WarCraft III: The Frozen Throne (Level: 2, icon tier Undead, peon icon, in clan LoF) and acquired ops.
[01:57:30 PM] Rank: 1
[01:57:30 PM] <Spiritless_LoF Hi Spiritless_One.>

This post has been edited by Spiritless: November 03, 2009 - 10:02 PM

Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#59 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 10:45 PM

Going back to what I said earlier, I made commands so that people don't have to edit these manually. If you don't know what you're doing, don't edit them manually and nothing will break.

Now, I don't know what you're doing because mine works perfectly.

Quote

'// Member greet display type; 1 - All Chat, 2 - Emote, 3 - Whisper
m_greet_dsp=3
'// Non-member greet display type; 1 - All Chat, 2 - Emote, 3 - Whisper
nm_greet_dsp=3
'// Member greet enabled?
m_greet_on=True
'// Non-member greet enabled?
nm_greet_on=True
'// Member greet message.
m_greet=Welcome back, %0. You are ranked %u - %r. You have %a Access.
'// Non-member greet message.
nm_greet=Omg you're not a member, %0.


Quote

[17:38:58.328] -- The_Black_Nin#2 [47ms] has joined the channel using WarCraft III: The Frozen Throne (Level: 6, icon tier Night Elf, peon icon, in clan Hang).
[17:34:57.390] <To The-Black-Ninja> Welcome back, The-Black-Ninja. You are ranked 7 - Murderer. You have 50 Access.

[17:36:40.750] -- The_Black_Nin#2 [47ms] has joined the channel using WarCraft III: The Frozen Throne (Level: 6, icon tier Night Elf, peon icon).
[17:36:40.906] <To The_Black_Nin#2> Omg you're not a member, The_Black_Nin#2.


I did, hopefully, fix it so that it won't greet a person with the generic member message if you set their rank to have a greet message.

#60 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 10:47 PM

Also, is there a way to have the crs set a players access AND Flags when they are promoted/demoted? the access works fine, and when i set someone to a rank, demote, or promote them, it changes the access to the bot just fine, but when i try to add flags also, when i load the script i get this error:

Quote

[02:46:49 PM] Scripting parsing error '1025' in crsClanRankScript.txt: (line 80; column 68)
[02:46:49 PM] Expected end of statement
[02:46:49 PM] Offending line: >> crsRanks(1) = "Overlord of Flame" : crsRankAccess(1) = 21 GRC


I use flags for some commands, but mainly for mass mail, so it's not THAT important, but it would be very helpful.

The code for this is:
crsRanks(1) = Overlord of Flame   : crsRankAccess = 21


That works perfectly, however this does not:
crsRanks(1) = Overlord of flame   : crsRankAccess = 21 GRC


This post has been edited by Spiritless: November 03, 2009 - 10:50 PM

Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#61 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 10:53 PM

That's because it wasn't set up to do that. I'll add it in though.

#62 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 10:54 PM

Ok thanks.
^,..,^

And the rank-specific greets work now.
Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#63 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 11:13 PM

Okay, in this next update, you guys need to go into your scripts.ini and find this group of text:

Quote

'// Enable auto-access system that will give out access based on a user's CRS rank.
'// Note: If you already have an auto-access script enabled, you will need to disable it if you plan on using this setting.
auto_access_on=True

Delete all that. I already had a setting to give the auto-access, I'm not exactly sure why I put it in here twice...it's not like it functions anyway, the entire script is set up to read off the original "aa_on" setting, so w/e.

Anyways, other than that, there's nothing else you need to do to make the script give them access and/or flags, I just need to explain how to do it in the FAQ.

Done. http://www.stealthbo...aqs-crs/#FAQ_AA

#64 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 11:18 PM

I deleted that part of the scripts.ini, reloaded scripts, and I still get this:

Quote

[03:15:35 PM] Scripting parsing error '1025' in crsClanRankScript.txt: (line 83; column 69)
[03:15:35 PM] Expected end of statement
[03:15:35 PM] Offending line: >> crsRanks(1) = "Overlord of Flame" : crsRankAccess(1) = 21 GRC

Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#65 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 11:19 PM

Quote

If you wish to have users gain both access and flags, the values should look like this: crsRankAccess(#) = "10 G"


#66 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 11:35 PM

Oh yay... I'm retarted.. I didn't think to include the " " :|
U can smack me on the head if u want to now. lol.


Also, I have noticed if you do .crsrank or .crsrankinfo or something liek that, if you don't include a name, it doesnt give you YOUR stats, it just does nothing... for example, the old crs if u typed .rank but no name, it would give YOUR rank, but typing .crsrank without a name does nothing. I don't mind really, just wanted to make sure u knew that incase u intended it to give YOUR info when u type .crsrank without a name.
Thank you very much TBN.

~~Spiritless~~

PS. I got a thank you in the channel log! lols.
Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#67 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 03, 2009 - 11:40 PM

Yeah, that was intended to do that, if it gets on people's nerves, I can change it.

#68 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 03, 2009 - 11:42 PM

ok, dnt really matter to me, my members can type their own names... i hope... lol

And theres a problem with the .crsset when using the ranks name still...

Quote

[03:44:42 PM] <Spiritless_One> .crsset misfitkid14 expert of flame
[03:44:43 PM] Scripting runtime error '5' in crs: (line 911; column 0)
[03:44:43 PM] Invalid procedure call or argument: 'Right'
[03:44:43 PM] Offending line: >>
[03:44:43 PM] Scripting runtime error '5' in crs: (line 911; column 0)
[03:44:43 PM] Invalid procedure call or argument: 'Right'
[03:44:43 PM] Offending line: >>

This post has been edited by Spiritless: November 03, 2009 - 11:45 PM

Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

#69 User is offline   Swent Icon

  • Newbie
  • Pip
  • Group: Members
  • Posts: 2
  • Joined: September-17 09

Posted November 04, 2009 - 08:08 AM

Fix author line, thread subtitle, and author line in script. Thanks.

#70 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 04, 2009 - 02:03 PM

Author line is fine. This version was made by me, the original was made by you and keep in mind, this wasn't a simple copy and paste, I rewrote many things. I've always given credit in the script itself, not the post.

#71 User is offline   Novynn Icon

  • Silver Member
  • PipPipPipPipPip
  • Group: Members
  • Posts: 873
  • Joined: October-07 09

Posted November 05, 2009 - 06:10 AM

CRS has worked fine up until now. This is a exert of my bots log:

Quote

[07:02:08 PM] <Neco> !crsSet naxxan 5
[07:02:09 PM] <Verus> " naxxan " has been added as a new member with the rank of 5 - Trooper
[07:02:10 PM] That is not a valid command. Type /help or /? for more info.
[07:02:14 PM] <Neco> !whois naxxan
[07:02:15 PM] <Verus> There was no such user found.
--------------------------
[07:02:30 PM] <Neco> !crspromote naxxan 1
[07:02:31 PM] <Verus> " naxxan " has been promoted to rank 4 - Lieutenant
[07:02:33 PM] That is not a valid command. Type /help or /? for more info.
[07:02:36 PM] <Neco> !whois naxxan
[07:02:36 PM] <Verus> There was no such user found.


I have the "AutoAccess" option in the scripts config set to "True" and yet it seems it does not work for adding or promoting members.

This is my ranks copied directly from the crsClanRankScript.txt file:

Quote

numRanks = 6 '// Highest number of ranks. Change this value after adding or removing ranks.

Quote

crsRanks(1) = "Commander" : crsRankAccess(1) = 200
crsRanks(2) = "Commisser" : crsRankAccess(2) = 200
crsRanks(3) = "Colonel" : crsRankAccess(3) = 80
crsRanks(4) = "Lieutenant" : crsRankAccess(4) = 60
crsRanks(5) = "Trooper" : crsRankAccess(5) = 20
crsRanks(6) = "Banned" : crsRankAccess(6) = 0


This is for the latest version of this script, and yet it does not seem to want to work with giving access.

EDIT: I also noticed that in my log, it showed:

Quote

That is not a valid command. Type /help or /? for more info.


This was after promoting someone (a mistyped AddQ prehaps?)

This post has been edited by Neco: November 05, 2009 - 06:15 AM


#72 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 05, 2009 - 06:31 AM

What setting did you enabled the auto access? aa_on? Seems to be working fine for me.

Quote

'// Enable CRS auto-access so when users are promoted to different ranks, their access will be automatically adjusted according to each rank's access setting.
aa_on=True

Quote

/crsset test 10
[01:30:53.109] "test" has been given rank 10.
[01:30:53.125] " test " has had their rank changed to rank 10 - Creed Probation Lvl 3

/crspromote test
[01:31:01.422] "test" has been given rank 10.
[01:31:01.437] " test " has been promoted to rank 9 - Creed Probation Lvl 4

'// With auto-access disabled
[01:32:52.125] <The-Black-Ninja> <3crspromote test
[01:32:52.312] <The_Black_Ninja> " test " has been promoted to rank 8 - Creed Probation Lvl 5

'// Auto access enabled
[01:35:40.062] <The-Black-Ninja> <3crspromote test
[01:35:40.140] "test" has been given rank 10.
[01:35:40.203] <The_Black_Ninja> " test " has been promoted to rank 7 - Murderer


#73 User is offline   Novynn Icon

  • Silver Member
  • PipPipPipPipPip
  • Group: Members
  • Posts: 873
  • Joined: October-07 09

Posted November 05, 2009 - 07:16 AM

Quote

'// Enable CRS auto-access so when users are promoted to different ranks, their access will be automatically adjusted according to each rank's access setting.
aa_on=True


Thats what I have, do you want me to bring my bot in Clan HANG to see yourself? I kind of just use CRS as my main access setter and would like this fixed ASAP.

#74 User is offline   The-Black-Ninja Icon

  • The Sex
  • PipPipPipPipPipPipPip
  • Group: Members
  • Posts: 2,526
  • Joined: August-01 09

Posted November 05, 2009 - 02:15 PM

I can't fix what I don't know what's broken. It's working fine for me. Post your GiveAccess sub.

#75 User is offline   Spiritless Icon

  • Me 1337 Plz?
  • PipPip
  • Group: Members
  • Posts: 31
  • Joined: September-12 09

Posted November 14, 2009 - 08:15 PM

I don't know when it started exactly, but i'm getting this error when using .crsset to set someone thats not in the database to a rank.. for example:

Quote

[12:04:08]<Legion_of_Flame> .crsset test 21
[12:04:08]Scripting runtime error '-2147467259' in crs (line 1508; column 0)
[12:04:08][Microsoft][ODBC Microsoft Access Driver] The field 'members.points' cannot contain a Null value because the Requiredbproperty for this field is set to True. Enter a value in this field.
[12:04:08]Offending line: >>
[12:04:08]Scripting runtime error '-2147467259' in crs (line 1508; column 0)
[12:04:08][Microsoft][ODBC Microsoft Access Driver] The field 'members.points' cannot contain a Null value because the Requiredbproperty for this field is set to True. Enter a value in this field.
[12:04:08]Offending line: >>
[12:04:08]Scripting runtime error '-2147467259' in crs (line 1508; column 0)
[12:04:08][Microsoft][ODBC Microsoft Access Driver] The field 'members.points' cannot contain a Null value because the Requiredbproperty for this field is set to True. Enter a value in this field.
[12:04:08]Offending line: >>

it repeats the error after the command 3 times then stops.

and also, when i try to .crsset using a rank name instead of a number, it still gives an error:

Quote

[12:04:15]<Legion_of_Flame> .crsset test recruit
[12:04:15]Scripting runtime error '5' in crs: (line 911; column 0)
[12:04:15]Invalid procedure call or argument: 'Right'
[12:04:15]Offending line: >>
[12:04:15]Scripting runtime error '5' in crs: (line 911; column 0)
[12:04:15]Invalid procedure call or argument: 'Right'
[12:04:15]Offending line: >>


The .crsset gives both those errors wether the command is through bnet or through the console using /crsset

This post has been edited by Spiritless: November 14, 2009 - 08:16 PM

Posted Image
Posted Image
ѕpiЯїtlЭЅЅ_οЦє

Champion of the Frozen Wasts - Legion of Frost - legionoffrost.tk

  • (9 Pages)
  • +
  • 1
  • 2
  • 3
  • 4
  • 5
  • Last »
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users