Main
Projects
Art
Music
Scripting
LiveJournal
Forum
Links
Stat Randomizer
by James `SPAM Man' Paige

It's not a great idea balance-wise, but, hey, AD&D did it, and it could be fun. It's a stat randomizer.


include, plotscr.hsd

# and example of randomizing heros stats

define script (1,randomize stats,0)

script,randomize stats,begin
  # you start with Washington
  add hero (hero:Jefferson)
  add hero (hero:Lincoln)
  add hero (hero:Roosevelt)

  variable (who,i)
  for (who,0,3) do,begin
     set hero stat (who,stat:HP ,random(70,110),maximumstat)
     set hero stat (who,stat:MP ,random(10,40) ,maximumstat)
     set hero stat (who,stat:Atk,random(20,30) ,maximumstat)
     set hero stat (who,stat:Aim,random(20,30) ,maximumstat)
     set hero stat (who,stat:Def,random(20,30) ,maximumstat)
     set hero stat (who,stat:Dog,random(20,30) ,maximumstat)
     set hero stat (who,stat:Mag,random(20,30) ,maximumstat)
     set hero stat (who,stat:Wil,random(20,30) ,maximumstat)
     set hero stat (who,stat:Spd,random(15,25) ,maximumstat)
     set hero stat (who,stat:MP~,random(0 ,10) ,maximumstat)

     #now we set the current stats to the max stats
     for (i,0,11),do,begin
        set hero stat(who,i,get hero stat(who,i,maximumstat),currentstat)
     end

  end

end

#--these constants are just here to make the example script compile.
#  you should remove them, and instead include your .HSI file, which will
#  contain your own stat and hero names.
define constant,begin
0, stat:HP
1, stat:MP
2, stat:Atk
3, stat:Aim
4, stat:Def
5, stat:Dog
6, stat:Mag
7, stat:Wil
8, stat:Spd
9, stat:Ctr
10, stat:MP~
11, stat:Hits
1,hero:Jefferson
2,hero:Lincoln
3,hero:Roosevelt
end


Site layout (c)2000 Jennifer Raby. Used by permission.