Detecting lowest level hero?

Odd lyoko

New Member
Reaction score
0
I have a hero war map, i stored each hero in an array variable called HERO[1-11] how do i make a trigger to detect lowest level hero and lvl him up by one level in GUI?
thanks
 

jig7c

Stop reading me...-statement
Reaction score
123
For Each Integer A from 1 to 11
Loop
Set Integer[A] = Level of Hero[A]
edit: custom script: call GetMin (Integer[1], Integer[11] //would this work? i doubt it.. never know.
i dont' know how to get the lowest number from here.. but its a start!
 

Slapshot136

Divide et impera
Reaction score
471
For Each Integer A from 1 to 11
Loop
Set Integer[A] = Level of Hero[A]

let me elaborate

you need a temp unit variable
set it to the first hero
then go through the list as jig7c showed, and then check if the hero[a] is a lower level then the one in the temp unit variable, if so, set it so that the temp unit variable is hero[a] - after this the temp variable should have the hero that is the lowest level, and then you can increase it by 1
 

jig7c

Stop reading me...-statement
Reaction score
123
link

here is a link that shows the lowest XP of the hero and gives him extra gold/xp...
all you would have to do it edit it for lowest level, and give him extra level!
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top