Gangster RPG
mIRC Code
+ 0 likes
Please Register to submit score.
| Average Score | 9.0 (of 4 scores) |
| Date Added | Nov 26, 2008 |
| Last Updated | Nov 27, 2008 |
| Tags | bot game gang roleplay rpg |
Introduction
Enjoy.
mIRC Snippet:
Gangster RPG
Posted on Nov 26, 2008 9:43 pm
Posted on Nov 26, 2008 9:43 pm
Comments and suggestions welcome as always. Constructive criticism encouraged, but inappropriate and rude comments will be deleted.
Ratings are always nice too. :)
Ratings are always nice too. :)
mIRC Snippet:
Gangster RPG
Posted on Nov 27, 2008 9:26 am
Posted on Nov 27, 2008 9:26 am
Changed from channel to message for .gangster command.
mIRC Snippet:
Gangster RPG
Posted on Nov 29, 2008 9:13 am
Posted on Nov 29, 2008 9:13 am
Great script `JoKeR´
I really like the way you use hash tables and just reading through is so cool, and makes understanding hash tables so much easier. Thank you for sharing :-)
Purcell:
See I'm editing my last post ;)
Not to sure with hash tables or how others will do it, just going through quickly I would do summin like
But not sure how what other ways there are to do this unless you set a variable to 1 and use hadd -z $2 jail %variablename - but that will totally unset it *shrugs* - Trial and error I guess hey ;)
I really like the way you use hash tables and just reading through is so cool, and makes understanding hash tables so much easier. Thank you for sharing :-)
Purcell:
See I'm editing my last post ;)
Not to sure with hash tables or how others will do it, just going through quickly I would do summin like
| Code: |
| if ($nick isop $chan) || ($nick === YourExactNickname) { if ($1 == !bust) { if (!$2) { .notice $nick Syntax: !bust nick | halt } hadd $2 jail 0 } } |
But not sure how what other ways there are to do this unless you set a variable to 1 and use hadd -z $2 jail %variablename - but that will totally unset it *shrugs* - Trial and error I guess hey ;)
mIRC Snippet:
Gangster RPG
Posted on Nov 29, 2008 12:36 pm
Posted on Nov 29, 2008 12:36 pm
Kasbah, thanks for the comment. Hash tables are easy once you figure out how they work and get over the intimidation they present with their own set of identifiers and aliases. It also seems you don't understand how the -z switch works, which is okay. The -z switch will unset your item after <item> seconds. So doing:
would be in lamens terms: add jail to $nick for 10 seconds, then delete.
| Code: |
| hadd -z $nick jail 10 |
mIRC Snippet:
Gangster RPG
Posted on Nov 29, 2008 2:59 pm
Posted on Nov 29, 2008 2:59 pm
| Quote: |
| It also seems you don't understand how the -z switch works |
I sort of know how the -z switch works I read the help file lol, was just one idea to set jail to 0 but the -z switch unsets it so wasn't sure if you still needed it to be set or not, the above example was just answering Purcell's question.
Otherwise I would have done it like this, which would decrease and unset in 1 second:
| Code: |
| var %temp 1 hadd -z $2 jail %temp |
Instead of
| Code: |
| hadd $2 jail 0 |
Purcell: I looked at the hash table help file for the first time ever today, so no I cannot help you as I am not skeeled enough, please Read the help file dude and please don't flood, if you have something to say and think of something later on to say, click EDIT and add what you wanted to say with your previous post.
mIRC Snippet:
Gangster RPG
Posted on Nov 29, 2008 5:30 pm
Posted on Nov 29, 2008 5:30 pm
You wouldn't want to do hadd $2 jail 0 because it would basically forever set jail to 0 until otherwise stated. The code looks to make sure that there is no "jail" in table "$nick", so instead of setting jail to 0, you would want to remove jail from the table using
| Code: |
| hdel $2 jail |
mIRC Snippet:
Gangster RPG
Posted on Nov 30, 2008 9:00 am
Posted on Nov 30, 2008 9:00 am
I wanne set: if u kil any u need wait 10 - 15mins to the next
can any set .attack script here with that if u kill 1 u need kill 10 - 15 mins for the next ? thx
Srry for the begin jonesy44!
can any set .attack script here with that if u kill 1 u need kill 10 - 15 mins for the next ? thx
Srry for the begin jonesy44!
mIRC Snippet:
Gangster RPG
Posted on Dec 26, 2008 8:47 am
Posted on Dec 26, 2008 8:47 am
i like the code... great use of hash tables... i have made a huge update for it... but one problem...
.attack name gives me this error, * Invalid format: $floor
this is the code unchanged from urs ...
var %b $floor($rand($calc(%a / 2),%a))
var %d $floor($rand($calc(%c / 2),%c))
how can it be fixed thanks... ill paste the update full version as soon as its fixed
.attack name gives me this error, * Invalid format: $floor
this is the code unchanged from urs ...
var %b $floor($rand($calc(%a / 2),%a))
var %d $floor($rand($calc(%c / 2),%c))
how can it be fixed thanks... ill paste the update full version as soon as its fixed
mIRC Snippet:
Gangster RPG
Posted on Dec 26, 2008 8:52 am
Posted on Dec 26, 2008 8:52 am
oh one more thing, i have made a top10 gangster lvl list and i have made it so it keeps the lvl money so on... changed commands !login added and it checks to see no clones so on... im a self taaught coder for about 4 months and thriving...
mIRC Snippet:
Gangster RPG
Posted on Dec 28, 2008 1:46 pm
Posted on Dec 28, 2008 1:46 pm
Col_fussion,
var %b $floor($rand($calc(%a/2),%a))
normal it works!
var %b $floor($rand($calc(%a/2),%a))
normal it works!
mIRC Snippet:
Gangster RPG
Posted on Jan 1, 2009 6:15 pm
Posted on Jan 1, 2009 6:15 pm
Cold_Fussion, can u post the Top and login script ?
mIRC Snippet:
Gangster RPG
Posted on Feb 9, 2009 4:32 pm
Posted on Feb 9, 2009 4:32 pm
oops forgot about it, will post what ive redone so far
on *:QUIT: {
if ($chan == #gangsters) {
writeini gangsters\ $+ $nick $+ .ini $nick logged 0
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now offline.
if (%login == $nick) {
unset %login
}
}
}
on *:PART:#gangsters: {
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now offline.
writeini gangsters\ $+ $nick $+ .ini $nick logged 0
if (%login == $nick) {
unset %login
}
}
on *:text:!play:#: {
%checkifexist = $exists($mircdir\gangsters\ $+ $nick $+ .ini)
if (%checkifexist == $true) {
if (%login == $null) {
set %login $nick
msg $nick type .login password
mode # +v $nick
halt
}
if (%login != $null) {
msg # $nick plz be patient as %login is busy logging in
halt
}
}
else {
msg $nick type .register gangster-name password
}
}
on *:text:start:?: {
msg $nick type .register gangster-name password or .login password to start
}
on *:text:.login*:?: {
set %loginattempt $getinfo($nick,pass)
if ($getinfo($nick,logged) == 1) { msg $nick Already Logged in | halt }
if (%login != $nick) {
msg $nick plz type !play in the main channel
halt
}
if (($nick == %login) && ($2 == %loginattempt)) {
unset %login
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now online. (3Level: $getinfo($nick,level)) $+ 10) ( $+ $server $+ )
writeini gangsters\ $+ $nick $+ .ini $nick logged 1
msg $nick 7Welcome To Gangsters v1.0
halt
}
if ((%login == $nick) && ($2 != %loginattempt)) {
msg $nick password incorrect
halt
}
}
on *:connect:{
var %x 0
var %y $read(gangster.txt,-1)
while %x < %y {
hload -si $gettok($read(gangster.txt,%y),1,32) gangster.ini $gettok($read(gangster.txt,%y),1,32)
inc %x
}
}
on *:text:.register*:?: {
%checkifexist = $exists($mircdir\gangsters\ $+ $nick $+ .ini)
if (%checkifexist == $true) {
.notice $nick you have a gangter already, $getinfo($nick,gangster)
halt
}
if !$2 || !$3 || $2 !isalnum || $3 !isalnum {
.notice $nick .register <gangster> <password>
}
if $gettok($read(gangster.txt,w,$2),2,32) !== $null {
.msg # That name has been taken.
halt
}
else {
writeini gangsters\ $+ $nick $+ .ini $nick Gangster $2
writeini gangsters\ $+ $nick $+ .ini $nick pass $3
writeini gangsters\ $+ $nick $+ .ini $nick cash 1000
writeini gangsters\ $+ $nick $+ .ini $nick atk 5
writeini gangsters\ $+ $nick $+ .ini $nick def 5
writeini gangsters\ $+ $nick $+ .ini $nick atk_mod 0
writeini gangsters\ $+ $nick $+ .ini $nick def_mod 0
writeini gangsters\ $+ $nick $+ .ini $nick points 0
writeini gangsters\ $+ $nick $+ .ini $nick level 1
write -l1 gangster.txt $calc($read(gangster.txt,-1) + 1)
write gangster.txt $nick $2
msg #gangsters Welcome to Gangsters, $2 $+($chr(40),$nick,$chr(41))
mode #gangsters +v $nick
writeini gangsters\ $+ $nick $+ .ini $nick logged 1
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now online. (3Level: $getinfo($nick,level)) $+ 10) ( $+ $server $+ )
msg $nick Type .help for a list of commands.
msg $nick 7Welcome To Gangsters v1.0
}
}
on *:QUIT: {
if ($chan == #gangsters) {
writeini gangsters\ $+ $nick $+ .ini $nick logged 0
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now offline.
if (%login == $nick) {
unset %login
}
}
}
on *:PART:#gangsters: {
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now offline.
writeini gangsters\ $+ $nick $+ .ini $nick logged 0
if (%login == $nick) {
unset %login
}
}
on *:text:!play:#: {
%checkifexist = $exists($mircdir\gangsters\ $+ $nick $+ .ini)
if (%checkifexist == $true) {
if (%login == $null) {
set %login $nick
msg $nick type .login password
mode # +v $nick
halt
}
if (%login != $null) {
msg # $nick plz be patient as %login is busy logging in
halt
}
}
else {
msg $nick type .register gangster-name password
}
}
on *:text:start:?: {
msg $nick type .register gangster-name password or .login password to start
}
on *:text:.login*:?: {
set %loginattempt $getinfo($nick,pass)
if ($getinfo($nick,logged) == 1) { msg $nick Already Logged in | halt }
if (%login != $nick) {
msg $nick plz type !play in the main channel
halt
}
if (($nick == %login) && ($2 == %loginattempt)) {
unset %login
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now online. (3Level: $getinfo($nick,level)) $+ 10) ( $+ $server $+ )
writeini gangsters\ $+ $nick $+ .ini $nick logged 1
msg $nick 7Welcome To Gangsters v1.0
halt
}
if ((%login == $nick) && ($2 != %loginattempt)) {
msg $nick password incorrect
halt
}
}
on *:connect:{
var %x 0
var %y $read(gangster.txt,-1)
while %x < %y {
hload -si $gettok($read(gangster.txt,%y),1,32) gangster.ini $gettok($read(gangster.txt,%y),1,32)
inc %x
}
}
on *:text:.register*:?: {
%checkifexist = $exists($mircdir\gangsters\ $+ $nick $+ .ini)
if (%checkifexist == $true) {
.notice $nick you have a gangter already, $getinfo($nick,gangster)
halt
}
if !$2 || !$3 || $2 !isalnum || $3 !isalnum {
.notice $nick .register <gangster> <password>
}
if $gettok($read(gangster.txt,w,$2),2,32) !== $null {
.msg # That name has been taken.
halt
}
else {
writeini gangsters\ $+ $nick $+ .ini $nick Gangster $2
writeini gangsters\ $+ $nick $+ .ini $nick pass $3
writeini gangsters\ $+ $nick $+ .ini $nick cash 1000
writeini gangsters\ $+ $nick $+ .ini $nick atk 5
writeini gangsters\ $+ $nick $+ .ini $nick def 5
writeini gangsters\ $+ $nick $+ .ini $nick atk_mod 0
writeini gangsters\ $+ $nick $+ .ini $nick def_mod 0
writeini gangsters\ $+ $nick $+ .ini $nick points 0
writeini gangsters\ $+ $nick $+ .ini $nick level 1
write -l1 gangster.txt $calc($read(gangster.txt,-1) + 1)
write gangster.txt $nick $2
msg #gangsters Welcome to Gangsters, $2 $+($chr(40),$nick,$chr(41))
mode #gangsters +v $nick
writeini gangsters\ $+ $nick $+ .ini $nick logged 1
msg #gangsters 7 $+ $nick $+ 10,3 $getinfo($nick,gangster) 10is now online. (3Level: $getinfo($nick,level)) $+ 10) ( $+ $server $+ )
msg $nick Type .help for a list of commands.
msg $nick 7Welcome To Gangsters v1.0
}
}
mIRC Snippet:
Gangster RPG
Posted on Aug 2, 2009 9:00 am
Posted on Aug 2, 2009 9:00 am
@kyle ... just load the script in u r BOT by pressing Alt+R and then type .help
@Joker
Sweet script :)) I love it .. kinda addicted
@Joker
Sweet script :)) I love it .. kinda addicted
mIRC Snippet:
Gangster RPG
Posted on Aug 2, 2009 5:42 pm
Posted on Aug 2, 2009 5:42 pm
is there an update version with more weapons etc?
mIRC Snippet:
Gangster RPG
Posted on Aug 23, 2009 10:04 am
Posted on Aug 23, 2009 10:04 am
I made a script excatly like this but with a little bit more stuff and no jail and everyone said that yours is like it, But i look and find out this has been here for a few months now how the hell did i NOT see it. lol :|.






