function HSSAddHero takes integer hssHero, string hssName, string hssIcon, string hssSStr, string hssSAgi, string hssSInt returns nothing
set udg_HSS_MaxHeroes = ( udg_HSS_MaxHeroes + 1 )
set udg_HSS_Hero[udg_HSS_MaxHeroes] = hssHero
set udg_HSS_HeroName[udg_HSS_MaxHeroes] = hssName
set udg_HSS_HeroIcon[udg_HSS_MaxHeroes] = hssIcon
set udg_HSS_HeroStartStrength[udg_HSS_MaxHeroes] = hssSStr
set udg_HSS_HeroStartAgility[udg_HSS_MaxHeroes] = hssSAgi
set udg_HSS_HeroStartIntelligence[udg_HSS_MaxHeroes] = hssSInt
endfunction
function HSSAddDT1 takes string DT returns nothing
set udg_HSS_DescriptionTextRow1[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT2 takes string DT returns nothing
set udg_HSS_DescriptionTextRow2[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT3 takes string DT returns nothing
set udg_HSS_DescriptionTextRow3[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT4 takes string DT returns nothing
set udg_HSS_DescriptionTextRow4[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT5 takes string DT returns nothing
set udg_HSS_DescriptionTextRow5[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT6 takes string DT returns nothing
set udg_HSS_DescriptionTextRow6[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT7 takes string DT returns nothing
set udg_HSS_DescriptionTextRow7[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT8 takes string DT returns nothing
set udg_HSS_DescriptionTextRow8[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT9 takes string DT returns nothing
set udg_HSS_DescriptionTextRow9[udg_HSS_MaxHeroes] = DT
endfunction
function HSSAddDT10 takes string DT returns nothing
set udg_HSS_DescriptionTextRow10[udg_HSS_MaxHeroes] = DT
endfunction
Name | Type | is_array | initial_value |
HSS_AgilityColorAndText | string | No | |
HSS_CanUseTheSameHeroes | boolean | No | |
HSS_DescriptionTextRow1 | string | Yes | |
HSS_DescriptionTextRow10 | string | Yes | |
HSS_DescriptionTextRow2 | string | Yes | |
HSS_DescriptionTextRow3 | string | Yes | |
HSS_DescriptionTextRow4 | string | Yes | |
HSS_DescriptionTextRow5 | string | Yes | |
HSS_DescriptionTextRow6 | string | Yes | |
HSS_DescriptionTextRow7 | string | Yes | |
HSS_DescriptionTextRow8 | string | Yes | |
HSS_DescriptionTextRow9 | string | Yes | |
HSS_DisplayAttributesAtTop | boolean | No | |
HSS_Hero | unitcode | Yes | |
HSS_HeroesLeft | integer | No | |
HSS_HeroIcon | string | Yes | |
HSS_HeroName | string | Yes | |
HSS_HeroSelected | boolean | Yes | |
HSS_HeroSelectedHeroWarning | string | No | |
HSS_HeroSelectedWarningDur | real | No | |
HSS_HeroStartAgility | string | Yes | |
HSS_HeroStartIntelligence | string | Yes | |
HSS_HeroStartStrength | string | Yes | |
HSS_IfPickedSelectViewColor | boolean | No | |
HSS_Integer | integer | Yes | |
HSS_IntelligenceColorAndText | string | No | |
HSS_MaxHeroes | integer | No | |
HSS_MultiboardName | string | No | |
HSS_NumberOfHeroesDisplayed | integer | No | |
HSS_Player_CurrentIndex | integer | Yes | |
HSS_Player_HeroSpawnLocation | rect | Yes | |
HSS_Player_Multiboard | multiboard | Yes | |
HSS_Player_ViewingMultiboard | boolean | Yes | |
HSS_PlayerGroup | force | No | |
HSS_Point | location | No | |
HSS_SelectedColor | string | No | |
HSS_StrengthColorAndText | string | No | |
HSS_ViewingColor | string | No |
###########################################################################################################
###########################################################################################################
################################ THE_FLOOD'S HERO SELECTION SYSTEM [HSS] ##################################
############################################# VERSION: 1.3a ###############################################
###########################################################################################################
This system is created by The_Flood (Flood @ hiveworkshop). Give credits when used or modified.
You may edit this system how much you want, but don't contact me if your changes does not work properly
because that isn't my problem, but if you haven't modified anything and the system isn't working as it
should, please contact me then! =)
The_Flood's Hero Selection System is a system that allow you to create an original way of hero selection. I
think a lot of players are tired of the old "tavern"-selections and then I came up with this. By using a
multiboard you can scroll heroes through a list, up and down, using your arrow-keys. An information text
will then be displayed to the right about the current selected hero. There's absolutely no limit of how
many heroes you can put into this system, the scroll feature will always make sure the correct heroes will
be shown.
This system is also MPI, allowing up to 12 players use it at the same time. I'm using
> > if GetLocalPlayer() == Player(udg_HSS_Integer[0] - 1) then < < to make sure each player has it's own
multiboard.
This system is user-friendly and has no leaks at all, so have fun using it!
###########################################################################################################
[How do I import this system?]
It's simple. Paste the whole folder "The_Floods HSS" into your map and make sure you've checked the
"[X] Automatically create unknown variables while pasting trigger data" in File > Preferences.
Also, you need to copy some script that can be found under the script folder called: "The_FloodsHSS.w3x" and
paste it at the same place in your map.
When you've done this, you can start using this system!
###########################################################################################################
[How do I setup this system?]
The only thing you'll have to do is to edit the stuffs in the "HSS Initialization" trigger. You can easily
read and change the variables there to make this system as you want it.
// This is the name of the multiboard.
Set HSS_MultiboardName = |cffFF8000The_Flood's Hero Selection System|r
// This is how many heroes you want to be visible at the same time at the "scroll-list".
Set HSS_NumberOfHeroesDisplayed = 5 // MAXIMUM IS 25!
// This is the color that the strength-text will be displayed with.
Set HSS_StrengthColorAndText = |c00FF0000Strength: |r
// This is the color that the agility-text will be displayed with.
Set HSS_AgilityColorAndText = |c0096FF96Agility: |r
// This is the color that the intelligence-text will be displayed with.
Set HSS_IntelligenceColorAndText = |c006969FFIntelligence: |r
// This is a boolean (true or false variable) that will allow you to determine if the heroes stats shall appear
// at the top of the descriptiontext or the bottom. (true = TOP, false = BOTTOM)
Set HSS_DisplayAttributesAtTop = True
// This is the color of the "viewing-text". This is the color that the current selected hero in the "scroll-list"
// will use.
Set HSS_ViewingColor = |cffFF8000
// This is the color of the "already-selected-text". All selected heroes names will be displayed with this color.
// This will only appear if HSS_CanUseTheSameHeroes is set to false. (Read below about this).
Set HSS_SelectedColor = |cffff0000
// This is where the selected hero will be created. Set one location for each player in your map.
// This is an example of Player 1's start location.
Set HSS_Player_HeroSpawnLocation[1] = (Playable map area)
// This is a boolean (true or false variable) that allow you to set if the same hero can be picked again or not.
// If you set it to false, the players can't pick this hero again.
// If you set it to true, the players can pick this hero again.
Set HSS_CanUseTheSameHeroes = False
// This is a boolean (true or false variable) that allow you to change if the players current selected hero
// shall be colored in your "view-color" (above) or shall be colored with your "selected-color" (above) if
// the hero is picked. This will only be used if HSS_CanUseTheSameHeroes is set to false.
Set HSS_IfPickedSelectViewColor = False
// This is the text that will appear if the hero a player wants to pick already is picked.
// This will only appear if HSS_CanUseTheSameHeroes is set to false.
Set HSS_HeroSelectedHeroWarning = |cffff0000Error:|r This hero has already been selected!
// This is the duration of how long time the text above will be displayed.
Set HSS_HeroSelectedWarningDur = 5.00
###########################################################################################################
[How do I add a hero to this system?]
It's extremely simple! You only need a minimum of two actions.
The most important one is this function:
Custom script: call HSSAddHero('Hpal', "Paladin", "ReplaceableTextures\\CommandButtons\\BTNHeroPaladin.blp", "22 (+2.7)", "13 (+1.5)", "17 (+1.8)")
It's very easy to use when you know how it works.
We'll start with the first argument: 'Hpal'.
This is the raw-code of your hero (the unit-type). You can see this by visit the Object Editor and press: Ctrl + D.
Next is the "Paladin".
This is the name of your hero.
3rd is: "ReplaceableTextures\\CommandButtons\\BTNHeroPaladin.blp"
This is the icon your hero shall have in this system.
WARNING: You MUST use two "\\" or else it won't work, in worst cases, world editor will crash.
4th: "22 (+2.7)"
This is the amount of strength your hero starts with and how much strength that is gained per level.
5th: "13 (+1.5)"
This is the amount of agility your hero starts with and how much agility that is gained per level.
and 6th: "17 (+1.8)"
This is the amount of intelligence your hero starts with and how much intelligence that is gained per level.
And now we're almost done! The only thing left is the description text for your hero. It's very simple to add this, just check
those functions out:
Custom script: call HSSAddDT1("Warrior Hero, exceptional at defense and augmenting nearby friendly troops.")
//This adds a text to the first description row for your hero.
Custom script: call HSSAddDT2("")
//This adds a text to the second description row for your hero.
Custom script: call HSSAddDT3("Range: Melee")
//This adds a text to the third description row for your hero.
and so on, very simple! :)
Warning: You should only use a maximum of 100 characters for each description row.
Warning: There's a maximum of 10 description rows (Custom script: call HSSAddDT10("LAST ONE").
Warning: You may create more of those by your own, but it's up to you. If something went wrong it's not my fault.
###########################################################################################################