BlackD User#1
11-12-2007, 19:45
Heyho.
I'll write this little tutorial, cause I think it's pretty useful to have something like this in the script to let you know how much money you've already made and what you used.
It should look like this:
The script starts at variables that carry the worth of the loot, eg.
:start
fastExiva _gp = 1
fastExiva _2handedsword = 400
fastExiva _yellowpiece = 150
then there should be variables that count how many uhs and mfs you have(keep in mind that it will only count the ones in opened bps), eg.
fastExiva _uhs1 = $countitems:58 0C$
#counts how many uhs you have
fastExiva _mfs1 = $countitems:3A 0B 00$
#counts how many mfs you have
then you put the whole script, eg.
setVeryFriendly
setMeleeKill ghoul
setLoot D7 0B
move xxxx
and at the end, before the gotoScriptLine 0(you can put it whereever you like, but I'd rather prefer to know how much I've gained after every single round) you put the counting, the message displaying how much you've gained and what's your profit and the reset of the variables, eg.
:counting
fastExiva _gpc = $countitems:D7 0B$
#counts how many gold you have
fastExiva _2handedswordc = $numericalexp:{$countitems:C1 0C$}*{$_2handed$}$
#counts how many 2handed swords you have
fastExiva _yellowpiecec = $numericalexp:{$countitems:1A 17$}*{$_yellowpiece$}$
#counts how many y pieces of cloth you have
:counting the waste
fastExiva _wasteuh = $numericalexp:{$_uhs1$}-{$countitems:58 0C$)$
#counts how many uhs you used
fastExiva _wastemfs = $numericalexp:{$_mfs1$}-{$countitems:3A 0B 00$}$
#counts how many mfs you used
fastExiva _waste = $numericalexp:{$numericalexp:{$numericalexp:{$_was teuh$}*175$}+{$numericalexp:{$_wastemfs$}*50$}$}+{ $_waste$)$
#counts how much your waste cost
:final counting
fastExiva _cmadetr = $numericalexp:{$numericalexp:{$_gpc$}+{$_2handedsw ordc$}$}+{$_yellowpiecec$}$
fastExiva _cmaderound = $numericalexp:{$_cmadetr$}-{$_cmade$}$
#counts how many cash you've made this round
fastExiva _cmade = $numericalexp:{$numericalexp:{$_gpc$}+{$_2handedsw ordc$}$}+{$_yellowpiecec$}$
#counts how many cash you've made at all
:displaying the messages
fastExiva < B4 11 $hex-tibiastr:{$_cmaderound$}GP this round.$
waitX 1
fastExiva < B4 11 $hex-tibiastr:{$_cmade$}GP at all.$
waitX 1
fastExiva < B4 11 $hex-tibiastr: Your profit is {$numericalexp:{$_cmade$}-{$_waste$}$}GP$
:clearing the variables
fastExiva _gp = 0
fastExiva _2handedsword = 0
fastExiva _yellowpiece = 0
fastExiva _uhs1 = 0
fastExiva _mfs1 = 0
fastExiva _wasteuh = 0
fastExiva _wastemfs = 0
fastExiva _cmadetr = 0
fastExiva _cmaderound = 0
and then finally you can get back to the begining of the script : )
I hope it'll help someone at least.
I'll write this little tutorial, cause I think it's pretty useful to have something like this in the script to let you know how much money you've already made and what you used.
It should look like this:
The script starts at variables that carry the worth of the loot, eg.
:start
fastExiva _gp = 1
fastExiva _2handedsword = 400
fastExiva _yellowpiece = 150
then there should be variables that count how many uhs and mfs you have(keep in mind that it will only count the ones in opened bps), eg.
fastExiva _uhs1 = $countitems:58 0C$
#counts how many uhs you have
fastExiva _mfs1 = $countitems:3A 0B 00$
#counts how many mfs you have
then you put the whole script, eg.
setVeryFriendly
setMeleeKill ghoul
setLoot D7 0B
move xxxx
and at the end, before the gotoScriptLine 0(you can put it whereever you like, but I'd rather prefer to know how much I've gained after every single round) you put the counting, the message displaying how much you've gained and what's your profit and the reset of the variables, eg.
:counting
fastExiva _gpc = $countitems:D7 0B$
#counts how many gold you have
fastExiva _2handedswordc = $numericalexp:{$countitems:C1 0C$}*{$_2handed$}$
#counts how many 2handed swords you have
fastExiva _yellowpiecec = $numericalexp:{$countitems:1A 17$}*{$_yellowpiece$}$
#counts how many y pieces of cloth you have
:counting the waste
fastExiva _wasteuh = $numericalexp:{$_uhs1$}-{$countitems:58 0C$)$
#counts how many uhs you used
fastExiva _wastemfs = $numericalexp:{$_mfs1$}-{$countitems:3A 0B 00$}$
#counts how many mfs you used
fastExiva _waste = $numericalexp:{$numericalexp:{$numericalexp:{$_was teuh$}*175$}+{$numericalexp:{$_wastemfs$}*50$}$}+{ $_waste$)$
#counts how much your waste cost
:final counting
fastExiva _cmadetr = $numericalexp:{$numericalexp:{$_gpc$}+{$_2handedsw ordc$}$}+{$_yellowpiecec$}$
fastExiva _cmaderound = $numericalexp:{$_cmadetr$}-{$_cmade$}$
#counts how many cash you've made this round
fastExiva _cmade = $numericalexp:{$numericalexp:{$_gpc$}+{$_2handedsw ordc$}$}+{$_yellowpiecec$}$
#counts how many cash you've made at all
:displaying the messages
fastExiva < B4 11 $hex-tibiastr:{$_cmaderound$}GP this round.$
waitX 1
fastExiva < B4 11 $hex-tibiastr:{$_cmade$}GP at all.$
waitX 1
fastExiva < B4 11 $hex-tibiastr: Your profit is {$numericalexp:{$_cmade$}-{$_waste$}$}GP$
:clearing the variables
fastExiva _gp = 0
fastExiva _2handedsword = 0
fastExiva _yellowpiece = 0
fastExiva _uhs1 = 0
fastExiva _mfs1 = 0
fastExiva _wasteuh = 0
fastExiva _wastemfs = 0
fastExiva _cmadetr = 0
fastExiva _cmaderound = 0
and then finally you can get back to the begining of the script : )
I hope it'll help someone at least.