HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

multiboard problem

08-28-2004, 03:00 AM#1
Mete0ra
alright here's my problem. i made a multiboard (2 columns 12 rows) and intend to use it as sort of an enhanced leaderboard, showing the player's chosen hero icon and number of kills (as well as team kills). I tried this trigger already for the update.

Code:
 Update
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Set Playerscore[(Player number of (Owner of (Killing unit)))] = Playerscore[((Player number of (Owner of (Killing unit))) + 1)]
        Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Playerscore[(Player number of (Owner of (Killing unit)))]))

I have 0 as the default number on the multiboard when it's created. I don't know if that has anything to do with it.

also i have no idea how to make the hero's icon appear next to the name of the player. This is typical hero arena hero selection system (unit enters region, yada yada yada).

I don't know if this is possible. I'm kind of new to triggering. All help is appreciated.
08-28-2004, 12:25 PM#2
AFB-DieHard
For the icon, you would just have to add to the UNIT ENTERS REGION BLAH TRIGGER that it sets the icon of the item BLAH to the icon of the hero, you could do this with ifs (if hero selected = bla set icon to bla)
08-28-2004, 02:19 PM#3
Mete0ra
Quote:
Originally Posted by AFB-DieHard
For the icon, you would just have to add to the UNIT ENTERS REGION BLAH TRIGGER that it sets the icon of the item BLAH to the icon of the hero, you could do this with ifs (if hero selected = bla set icon to bla)

alright thanks .. i knew it had to be kind of obvious .. and i did figure out the other problem too .. it was obvious too.. all you have to do is:

Set Kills = (String(((Owner of (Killing unit)) Heroes Killed)))

also, for adding the other players scores, do I string the If/Then/Elses or do I leave them seperate? and if they are seperate, what do i do for else?

edit: i'm testing this trigger now ...

Code:
Update 1
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Set CreepKills = (String(((Owner of (Killing unit)) Units Killed)))
        Set Kills = (String(((Owner of (Killing unit)) Heroes Killed)))
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                ((Dying unit) is A Hero) Equal to True
            Then - Actions
                Multiboard - Set the text for (Last created multiboard) item in column 2, row (Player number of (Owner of (Killing unit))) to Kills
            Else - Actions
                Multiboard - Set the text for (Last created multiboard) item in column 3, row (Player number of (Owner of (Killing unit))) to CreepKills
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                ((Dying unit) is Summoned) Equal to True
            Then - Actions
                Do nothing
            Else - Actions
                Do nothing

Also, when setting the variable (CreepKills), does "Units Killed" count as creeps? and if not, what should i put there to make it creeps only?