//The function below creates a message similar to the error messages like "Not enough mana", but, unfortunately,
//position of this message quite far from where it must be. Such functions needed because it makes trigger usage more easier.
//Comment made Serik to understand this function
function SimError takes player ForPlayer, string msg returns nothing
if udg_SimError==null then
set udg_SimError=CreateSoundFromLabel( "InterfaceError",false,false,false,10,10)
endif
if (GetLocalPlayer() == ForPlayer) then
call ClearTextMessages()
call DisplayTimedTextToPlayer( ForPlayer, 0.52, -1.00, 2.00, "|cffffcc00"+msg+"|r" )
call StartSound( udg_SimError )
endif
endfunction
Name | Type | is_array | initial_value |
A | integer | No | |
A_ORB | unit | Yes | |
A_Orb | real | No | |
A_Orb2 | real | No | |
AA | integer | Yes | |
AB | integer | No | |
Abaddon | unit | No | |
AfAbilityStun | abilcode | No | |
Aftershock | abilcode | No | |
akasha | group | No | |
All_Random | boolean | No | |
Aphotic | hashtable | No | |
Aphotic_Shiel_Expiration_Timer | timer | No | |
Aphotic_Shield | effect | No | |
Aphotic_Shield_Caster | unit | No | |
Aphotic_Shield_Caster_Alive | unit | No | |
Aphotic_Shield_Effect | effect | No | |
Aphotic_Shield_Health | real | No | |
Aphotic_Shield_Health_Adder | real | No | |
Aphotic_Shield_Target | unit | No | |
Aplav_text | texttag | Yes | |
Arrow_point | location | No | |
Arrow_point2 | location | No | |
AS | unit | No | |
AS_Life | real | No | |
AS_Target | unit | No | |
AScheck | real | No | |
ATATA | lightning | No | |
Avatar | unit | No | |
Axe | unit | No | |
B1T | integervar | No | |
BacktrackUnit | unit | No | |
Beast_Attack_Ability_Level | integer | No | |
Beast_Attack_Atribute | integer | No | |
Beast_Attack_Atribute_Damage | real | No | |
Beast_Attack_Caster | unit | No | |
Beast_Attack_Damage_Splitter | integer | No | |
Beast_Attack_Life_Damage | real | No | |
Beast_Attack_Location | location | No | |
Beast_Attack_Location2 | location | No | |
Beast_Attack_Max_Life | real | No | |
Beast_Attack_Target | unit | No | |
Beast_Attack_Total_Damage | real | No | |
BerserkCalled | group | No | |
Blink_point | location | No | |
Blink_point2 | location | No | |
Blinked | boolean | Yes | |
BLoc | location | Yes | |
Borrowed_Time_Caster | unit | No | |
Borrowed_Time_Caster_Alive | unit | No | |
Borrowed_Time_Expiration_Timer | timer | No | |
Borrowed_Time_Health | real | No | |
BR_Effect | effect | Yes | |
BR_Effect01 | effect | Yes | |
BR_Effect02 | effect | Yes | |
BR_Effect03 | effect | Yes | |
BR_Effect2 | effect | Yes | |
BR_Effect3 | effect | Yes | |
BR_Integer | integer | No | |
BR_Integer2 | integer | No | |
BR_Owner | unit | No | |
BR_TargetArea | location | No | |
BR_TargetArea2 | location | No | |
BR_Temppoint001 | location | No | |
BR_Temppoint0012 | location | No | |
BR_Temppoint002 | location | No | |
BR_Temppoint0022 | location | No | |
BR_Tempunit | unit | No | |
BR_UnitGroup | group | No | |
BR_UnitGroup1 | group | No | |
BR_UnitGroup2 | group | No | |
BR_UnitGroup22 | group | No | |
BS_Ability | abilcode | Yes | |
BS_Angle | real | No | |
BS_Caster | unit | No | |
BS_Caster_Point | location | No | |
BS_Distance | real | No | |
BS_Distance_of_Impale | real | No | |
BS_Dummy | unit | No | |
BS_Facing | real | No | |
BS_Impale_Level | integer | No | |
BS_Integer | integervar | No | |
BS_Move_Point | location | No | |
BS_Number | real | No | |
BS_Target_Point | location | No | |
BS_unit | unit | Yes | |
BT2 | integervar | No | |
BT_Angle | real | Yes | |
BT_Dummy | unit | Yes | |
BT_Equation | real | Yes | |
BT_Group | group | Yes | |
BT_Group1 | group | No | |
BT_Hero | unit | Yes | |
BT_Loop | integer | No | |
BT_Main_Point | location | Yes | |
BT_Max_Distance | real | Yes | |
BT_Off | boolean | Yes | |
BT_Offset | real | Yes | |
BT_Part | integer | Yes | |
BT_Point | location | Yes | |
BT_Positive | integer | Yes | |
BT_Special | effect | Yes | |
BT_Speed | real | Yes | |
BT_Take_Dist | real | Yes | |
BT_Times | integer | No | |
BTally | unit | Yes | |
CasterDummy | unitcode | No | |
CastingUnit4 | unit | No | |
CF_Snd | integer | No | |
Chain_Missile | unit | No | |
ChainFrost_Group | group | No | |
ChainFrost_Jumps | integer | No | |
ChanceRoll | integer | No | |
Chaos_dmg | integer | No | |
Chaos_stun | integer | No | |
Check | integer | No | |
Chrono_Caster | unit | No | |
Chrono_Effecter | unit | No | |
Chrono_Group | group | No | |
Clock | unit | Yes | |
CMBOARD | multiboard | No | |
Cmheroes | unitcode | Yes | |
Coil | unit | No | |
Coiled | group | No | |
Coiler | unit | No | |
Color | string | Yes | |
CounterHelixCD | integer | No | |
Crixalis | unit | No | |
crystlnova | effect | No | |
Custom_Dream | integer | No | |
DamageTaken | real | No | |
DArki_number | integer | No | |
DashCaster | unit | Yes | |
DashDamage | real | Yes | |
DashDistance | integer | Yes | |
DashGroup1 | group | No | |
DashGroup2 | group | No | |
DashGroup3 | group | No | |
DashInteger | integer | Yes | |
DashPoint3 | location | Yes | |
DashPoint4 | location | Yes | |
DashPoint5 | location | Yes | |
DashReal1 | real | Yes | |
DashReal2 | real | Yes | |
DashSpeed | real | Yes | |
Deaths | integer | Yes | |
Degree | real | Yes | |
Dis_Con | real | No | |
Distance | real | No | |
Dlya_aa_af | player | Yes | |
Double | integer | Yes | |
Dream_Lightning | lightning | Yes | |
Dream_Target | unit | No | |
Earthshaker | unit | No | |
EchoSlam | abilcode | No | |
Elune_Arrow | unit | Yes | |
Enchant_Totem | abilcode | No | |
Enemy | unit | No | |
Enemy1 | unit | No | |
Enemy_____________________u | unit | No | |
Epicenter_AI | boolean | No | false |
ER_Angel | real | Yes | |
ER_Group | group | No | |
Er_Group2 | group | No | |
ER_TARGER | unit | Yes | |
ER_TOCHKA | location | Yes | |
Faceless_Void | unit | No | |
First_Blood | boolean | No | |
FissuDECOR | destructable | Yes | |
Fissure | integer | No | |
Fissure_Caster | unit | No | |
Fissurepoint | location | Yes | |
FloatingText | texttag | No | |
For_runes_integer | integer | Yes | |
FreezeEffect | effect | No | |
Freezer | unit | No | |
Game_End | boolean | No | |
Game_Start | timer | No | |
GamemodeSet | integer | No | |
GDD__Integers | integer | Yes | |
GDD__LeftMapGroup | group | No | |
GDD__TriggerArray | trigger | Yes | |
GDD__UnitArray | unit | Yes | |
GDD_Damage | real | No | |
GDD_DamagedUnit | unit | No | |
GDD_DamageSource | unit | No | |
GDD_Event | real | No | |
Gery | unit | Yes | |
GI_Caster | unit | No | |
GI_EnemysGroup | group | No | |
GI_SpecEffect | effect | No | |
GI_TargetPoint | location | No | |
Hero_scor | unitcode | Yes | |
Hero_sent | unitcode | Yes | |
Hero_vse | unitcode | Yes | |
HeroType | player | Yes | |
Hostnumber | integer | No | |
HydroCaster | unit | Yes | |
HydroCastPoint | location | Yes | |
HydroCounter | integer | Yes | |
HydroLength | real | Yes | |
HydroTargetpos | location | Yes | |
HydroUsers | integer | No | |
HydroWavepos | location | Yes | |
HydroWaveTargets | group | Yes | |
Iconki_DlyBorda | string | Yes | |
Iconki_DlyCM | string | Yes | |
IgnitePillarGroup | group | No | |
illuminate_angle | real | No | |
illuminate_caster | unit | No | |
illuminate_dummys | unit | Yes | |
illuminate_point | location | No | |
illuminate_time | integer | Yes | |
IlluOrbOn | integer | No | |
IntegerToMoveCastingUnit4 | integer | No | |
IntegerToMoveCastingUnit7 | integer | No | |
Item | itemcode | Yes | |
Item_Counter | integer | Yes | |
Item_Counter2 | integer | Yes | |
Item_Owner | unit | Yes | |
Juggernaut2 | unit | No | |
Kill_Count | integer | Yes | |
Kill_Waiting_Time | integer | Yes | |
KillLimitSet | integer | No | |
KillMessages_List | string | Yes | |
Kills | integer | Yes | |
KillspreeEndMessages_List | string | Yes | |
Knockback_Loc1 | location | No | |
Knockback_Loc2 | location | No | |
Knockback_Target | unit | No | |
KnockbackAngle | real | No | |
KnockbackDistance | real | No | |
KnockbackSpeed | real | No | |
KnockbackTable | hashtable | No | |
KnockbackUnits | group | No | |
Krobelus | unit | No | |
Kunkka | unit | No | |
Leap | hashtable | No | |
Leap_Angel | real | Yes | |
Leap_Distance | real | No | |
Leap_Height | real | No | |
Leap_tochka | location | Yes | |
Leap_Units | group | No | |
Leshrac | unit | No | |
Levithian | unit | No | |
lf9 | real | No | |
lfa | real | No | |
Lich | unit | No | |
Lich_Point | location | No | |
llalala | integer | No | |
M_Min | integer | No | |
M_Sec | integer | No | |
Magnus_naumber | integer | No | |
Magnus_naumber2 | integer | No | |
Make_Kill | boolean | No | |
Max_Jumps | integer | No | |
MBoard | multiboard | No | |
MH_Angel2 | real | No | |
MH_Angle | real | No | |
MH_Level | integer | No | |
MH_Link | unit | Yes | |
MH_Link2 | unit | Yes | |
MH_Links | integer | No | |
MH_Links2 | integer | No | |
MH_Unit | unit | Yes | |
Mine | unit | No | |
Minutes | integer | No | |
Mirana | unit | No | |
Missile_Point | location | No | |
Modifier | fogmodifier | No | |
Mogul_Khan | unit | No | |
Morphling | unit | No | |
MS | integer | No | |
Mult | integer | Yes | |
MultiKilling_Spree | integer | Yes | |
Necrolyte | unit | No | |
Nether_Point | location | No | |
Nether_Swap | integer | No | |
Nevermore | unit | No | |
Noherolimit | boolean | No | |
NOKI_X | integer | Yes | |
Nova_Damage | abilcode | No | |
Nova_Point | location | No | |
Nova_Target | unit | No | |
Nugno_Kills | integer | No | 50 |
Number | integer | No | 25 |
Offset_Point | location | No | |
OgreMagi | unit | No | |
omni_caster | unit | No | |
omni_current_point | location | No | |
omni_grop | group | No | |
omni_grop2 | group | No | |
omni_loops | integer | No | |
omni_point | location | No | |
omni_point2 | location | No | |
omni_se | effect | No | |
omni_se2 | effect | No | |
omni_target | unit | No | |
omni_target_2 | unit | No | |
omnieffect1 | effect | No | |
Omnitarget | unit | No | |
OR_Angel | real | Yes | |
OR_GROUP | group | Yes | |
OR_Tocha | location | Yes | |
Orb_otrad | group | Yes | |
Orb_otrad2 | group | No | |
Orb_point | location | No | |
Orb_point2 | location | No | |
Otryad | group | Yes | |
pEU | unit | No | |
pf7 | real | No | |
Player | unit | Yes | |
PlayerGroup | force | No | |
PlayerHashScourge | hashtable | Yes | |
PlayerHashSent | hashtable | Yes | |
Players_Name | string | Yes | |
Position_Spells | location | Yes | |
Predmet | item | Yes | |
Puck | unit | No | |
Pudge | unit | No | |
Raal | real | No | |
RANDname | string | No | |
random | integer | No | |
Random_scor | integer | No | |
Random_sent | integer | No | |
Random_vse | integer | No | |
RastOFtoss | integer | Yes | |
RE_Knocktable | hashtable | No | |
Reality_Rift_Distance | real | No | |
Reality_Rift_Point | location | No | |
Region | location | Yes | |
Requiem | boolean | No | |
requiem_caster | unit | No | |
Respawn | integer | No | |
Respawn_Time | real | No | |
Rexxar | unit | No | |
RNGInteg | integer | No | |
RNGReal | real | No | |
RNGUnit | unit | No | |
RNGUnitGroup | group | No | |
Runes | itemcode | Yes | |
RylaiUltiOn | integer | No | |
rylaiultiseccounter | integer | No | |
RylaiUltiUnit | unit | No | |
rylaiultiweather | weathereffect | No | |
Rylaivar | unit | No | |
Sand | group | No | |
Sand_Storm | unit | No | |
Scor_max | integer | No | |
Seconds | integer | No | |
Sent_max | integer | No | |
Shadunit | unit | Yes | |
shiptochka | location | No | |
shipygol | real | No | |
SimError | sound | No | |
Slardar | unit | No | |
SoP | integer | No | |
Sounds_List | sound | Yes | |
SpecialFX | effect | No | |
StarfallGroup | group | No | |
StarfallSFX | effect | No | |
Start__orb | location | Yes | |
Swap | rect | Yes | |
Swappoint | location | Yes | |
swapunit | unit | Yes | |
Targets | group | No | |
techievar | unit | No | |
Telekines_angel | real | Yes | |
Telekines_group | group | No | |
Telekines_tochka | location | No | |
Telekines_tochka2 | location | No | |
Telekines_unit | unit | Yes | |
Temp_Group | group | No | |
Temp_Group2 | group | No | |
TempPoint | location | No | |
Test | boolean | No | |
Testovik | integer | No | |
Text_plav | texttag | No | |
Tidebringer | unit | No | |
TideTarget | unit | No | |
timer_test | timer | No | |
Tiny | unit | No | |
Tormented_Soul | unit | No | |
Toss_angel | real | Yes | |
Toss_Caster | unit | No | |
Toss_Dist | real | No | |
Toss_group | group | No | |
Toss_point | location | Yes | |
Toss_point1 | location | No | |
Toss_point2 | location | No | |
Toss_targer | unit | Yes | |
Toss_tochka | location | Yes | |
Tossable | group | No | |
TossAngle | real | No | |
TossDistance | integer | No | |
Tossee | unit | No | |
TosseeHeight | real | No | |
TosseePoint | location | No | |
Tosser | unit | No | |
TosserPoint | location | No | |
TossFire | effect | No | |
TossHeight | real | No | |
TossMidDistance | integer | No | |
TossOffset | real | No | |
TossRemainingDistance | real | No | |
TossSpeed | integer | No | |
TossTarget | unit | No | |
TossTargetPoint | location | No | |
Total_Messages | integer | No | |
tst | unit | No | |
Turn | string | Yes | |
Ugol | real | No | |
Ugol2 | real | No | |
Virtual_host | integer | No | |
VSE_max | integer | No | |
Weather | weathereffect | No | |
Y_Map_Point | location | Yes | |
Y_Wish_Group | group | Yes | |
Zeus | unit | No | |
Zeus_ult | unit | Yes |
//TESH.scrollpos=72
//TESH.alwaysfold=0
//*********************************************************************************************
//* GUI-Friendly Damage Detection -- v1.2.0 -- by Weep *
//* *
//* Requires: only this trigger and its variables. *
//* *
//* -- What? -- *
//* This snippet provides a leak-free, GUI-friendly implementation of an "any unit takes *
//* damage" event. It requires no JASS knowledge to use. *
//* *
//* It uses the Game - Value Of Real Variable event as its method of activating other *
//* triggers, and passes the event responses through a few globals. *
//* *
//* -- Why? -- *
//* The traditional GUI method of setting up a trigger than runs when any unit is damaged *
//* leaks trigger events. This snippet is easy to implement and removes the need to do *
//* you own GUI damage detection setup. *
//* *
//* -- How To Implement -- *
//* 1. Be sure "Automatically create unknown variables while pasting trigger data" is *
//* enabled in the World Editor general preferences. *
//* 2. Copy this trigger category ("GDD") and paste it into your map. *
//* (Alternately: create the variables listed below, create a trigger named *
//* "GUI Friendly Damage Detection", and paste in this entire text.) *
//* 3. Create your damage triggers using Game - Value Of Real Variable as the event, *
//* select GDD_Event as the variable, and leave the rest of the settings to the default *
//* "becomes Equal to 0.00". *
//* The event responses are the following variables: *
//* GDD_Damage is the amount of damage, replacing Event Response - Damage Taken. *
//* GDD_DamagedUnit is the damaged unit, replacing Event Response - Triggering Unit. *
//* GDD_DamageSource is the damaging unit, replacing Event Response - Damage Source. *
//* *
//* -- Notes -- *
//* Don't write any values to the variables used as the event responses, or it will mess *
//* up any other triggers using this snippet for their triggering. Only use their values. *
//* *
//* This uses arrays, so can have a maximum of 8190 instances at a time, and cleans up *
//* data at a rate of 33.33 per second. This should be enough for most maps. *
//* *
//* -- Credits -- *
//* Captain Griffin on wc3c.net for the research and concept of GroupRefresh. *
//* *
//* Credit in your map not needed, but please include this README. *
//* *
//* -- Version History -- *
//* 1.2.0: Made this snippet work properly with recursive damage. *
//* 1.1.1: Added a check in order to not index units with the Locust ability (dummy units).*
//* If you wish to check for damage taken by a unit that is unselectable, do not *
//* give the unit-type Locust in the object editor; instead, add the Locust ability *
//* 'Aloc' via a trigger after its creation, then remove it. *
//* 1.1.0: Added a check in case a unit gets moved out of the map and back. *
//* 1.0.0: First release. *
//* *
//*********************************************************************************************
//globals
// real udg_GDD_Event
// real udg_GDD_Damage
// unit udg_GDD_DamagedUnit
// unit udg_GDD_DamageSource
// trigger array udg_GDD__TriggerArray
// integer array udg_GDD__Integers
// unit array udg_GDD__UnitArray
// group udg_GDD__LeftMapGroup
//endglobals
function GDD_Event takes nothing returns boolean
local unit damagedcache = udg_GDD_DamagedUnit
local unit damagingcache = udg_GDD_DamageSource
local real damagecache = udg_GDD_Damage
set udg_GDD_DamagedUnit = GetTriggerUnit()
set udg_GDD_DamageSource = GetEventDamageSource()
set udg_GDD_Damage = GetEventDamage()
set udg_GDD_Event = 1.
set udg_GDD_Event = 0.
set udg_GDD_DamagedUnit = damagedcache
set udg_GDD_DamageSource = damagingcache
set udg_GDD_Damage = damagecache
set damagedcache = null
set damagingcache = null
return false
endfunction
function GDD_AddDetection takes nothing returns boolean
// if(udg_GDD__Integers[0] > 8190) then
// call BJDebugMsg("GDD: Too many damage events! Decrease number of units present in the map or increase recycle rate.")
// ***Recycle rate is the number used in the TimerStart line at the bottom of this trigger. Smaller is faster.***
// return
// endif
if(IsUnitInGroup(GetFilterUnit(), udg_GDD__LeftMapGroup)) then
call GroupRemoveUnit(udg_GDD__LeftMapGroup, GetFilterUnit())
else
if(GetUnitAbilityLevel(GetFilterUnit(), 'Aloc') == 0) then
set udg_GDD__Integers[0] = udg_GDD__Integers[0]+1
set udg_GDD__UnitArray[udg_GDD__Integers[0]] = GetFilterUnit()
set udg_GDD__TriggerArray[udg_GDD__Integers[0]] = CreateTrigger()
call TriggerRegisterUnitEvent(udg_GDD__TriggerArray[udg_GDD__Integers[0]], udg_GDD__UnitArray[udg_GDD__Integers[0]], EVENT_UNIT_DAMAGED)
call TriggerAddCondition(udg_GDD__TriggerArray[udg_GDD__Integers[0]], Condition(function GDD_Event))
endif
endif
return false
endfunction
function GDD_PresetDetection takes nothing returns nothing
local group g = CreateGroup()
local integer i = 0
set i = 0
loop
call GroupEnumUnitsOfPlayer(g, Player(i), Condition(function GDD_AddDetection))
call GroupClear(g)
set i = i+1
exitwhen i == bj_MAX_PLAYER_SLOTS
endloop
call DestroyGroup(g)
set g = null
endfunction
function GDD_GroupRefresh takes nothing returns nothing
//Based on GroupRefresh by Captain Griffen on wc3c.net
if (bj_slotControlUsed[5063] == true) then
call GroupClear(udg_GDD__LeftMapGroup)
set bj_slotControlUsed[5063] = false
endif
call GroupAddUnit(udg_GDD__LeftMapGroup, GetEnumUnit())
endfunction
function GDD_Recycle takes nothing returns nothing
if(udg_GDD__Integers[0] <= 0) then
return
elseif(udg_GDD__Integers[1] <= 0) then
set udg_GDD__Integers[1] = udg_GDD__Integers[0]
endif
if(GetUnitTypeId(udg_GDD__UnitArray[udg_GDD__Integers[1]]) == 0) then
call DestroyTrigger(udg_GDD__TriggerArray[udg_GDD__Integers[1]])
set udg_GDD__TriggerArray[udg_GDD__Integers[1]] = null
set udg_GDD__TriggerArray[udg_GDD__Integers[1]] = udg_GDD__TriggerArray[udg_GDD__Integers[0]]
set udg_GDD__UnitArray[udg_GDD__Integers[1]] = udg_GDD__UnitArray[udg_GDD__Integers[0]]
set udg_GDD__UnitArray[udg_GDD__Integers[0]] = null
set udg_GDD__Integers[0] = udg_GDD__Integers[0]-1
endif
set udg_GDD__Integers[1] = udg_GDD__Integers[1]-1
endfunction
function GDD_LeaveMap takes nothing returns boolean
local boolean cached = bj_slotControlUsed[5063]
if(udg_GDD__Integers[2] < 64) then
set udg_GDD__Integers[2] = udg_GDD__Integers[2]+1
else
set bj_slotControlUsed[5063] = true
call ForGroup(udg_GDD__LeftMapGroup, function GDD_GroupRefresh)
set udg_GDD__Integers[2] = 0
endif
call GroupAddUnit(udg_GDD__LeftMapGroup, GetFilterUnit())
set bj_slotControlUsed[5063] = cached
return false
endfunction
//===========================================================================
function InitTrig_GUI_Friendly_Damage_Detection takes nothing returns nothing
local region r = CreateRegion()
call RegionAddRect(r, GetWorldBounds())
call TriggerRegisterEnterRegion(CreateTrigger(), r, Condition(function GDD_AddDetection))
call TriggerRegisterLeaveRegion(CreateTrigger(), r, Condition(function GDD_LeaveMap))
call GDD_PresetDetection()
call TimerStart(CreateTimer(), 0.03, true, function GDD_Recycle)
set r = null
endfunction
function Trig_Multiboard_Actions takes nothing returns nothing
local integer a = 1
local integer b = 1
call CreateMultiboardBJ( 3, ( 6 + CountPlayersInForceBJ(udg_PlayerGroup) ), "DotA Fun-Wars" )
set udg_MBoard = GetLastCreatedMultiboard()
// String 1
loop
exitwhen a > 3
call MultiboardSetItemWidthBJ( udg_MBoard, a, 1, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, 1, false, false )
call MultiboardSetItemWidthBJ( udg_MBoard, a, 2, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, 2, false, false )
set a = a + 1
endloop
call MultiboardSetItemWidthBJ( udg_MBoard, 2, 1, 16 )
call MultiboardSetItemStyleBJ( udg_MBoard, 2, 1, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 2, 1, "|c00A3B7F5Tme ("+I2S(udg_M_Min)+":0"+I2S(udg_M_Sec)+")|r" )
call MultiboardSetItemWidthBJ( udg_MBoard, 1, 2, 10 )
call MultiboardSetItemStyleBJ( udg_MBoard, 1, 2, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 1, 2, "|c00FF80FF East force|r" )
call MultiboardSetItemWidthBJ(udg_MBoard, 2, 2, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, 2, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, 2, (I2S(udg_Kills[13]) ) )
call MultiboardSetItemWidthBJ(udg_MBoard, 3, 2, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, 2, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 3, 2, (I2S(udg_Deaths[13]) ) )
set b = 3
// Auril
set a = 0
loop
exitwhen a > 5
if ( GetPlayerController(Player(a)) == MAP_CONTROL_USER ) and ( GetPlayerSlotState(Player(a)) == PLAYER_SLOT_STATE_PLAYING ) then
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, true )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, ( udg_Color[a+1] + GetPlayerName(Player(a)) ))
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[a+1]) ))
call MultiboardSetItemWidthBJ(udg_MBoard, 3, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 3, b, (I2S(udg_Deaths[a+1]) ) )
set udg_Mult[a+1] = b
set b = b + 1
endif
set a = a + 1
endloop
set a = 1
loop
exitwhen a > 3
call MultiboardSetItemWidthBJ( udg_MBoard, a, b, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, b, false, false )
set a = a + 1
endloop
// Goharol
call MultiboardSetItemWidthBJ( udg_MBoard, 1, b, 10 )
call MultiboardSetItemStyleBJ( udg_MBoard, 1, b, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 1, b, "|c00000000 West foce|r" )
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[14]) ) )
call MultiboardSetItemWidthBJ(udg_MBoard, 3, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 3, b, (I2S(udg_Deaths[14]) ) )
set b = b + 1
set a = 6
loop
exitwhen a > 11
if ( GetPlayerController(Player(a)) == MAP_CONTROL_USER ) and ( GetPlayerSlotState(Player(a)) == PLAYER_SLOT_STATE_PLAYING ) then
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, true )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, ( udg_Color[a+1] + GetPlayerName(Player(a)) ))
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[a+1]) ) )
call MultiboardSetItemWidthBJ(udg_MBoard, 3, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 3, b, (I2S(udg_Deaths[a+1]) ) )
set udg_Mult[a+1] = b
set b = b + 1
endif
set a = a + 1
endloop
call TriggerSleepAction( 0.10 )
set a = 1
loop
exitwhen a > 3
call MultiboardSetItemWidthBJ( udg_MBoard, a, b, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, b, false, false )
set a = a + 1
endloop
call MultiboardSetItemWidthBJ( udg_MBoard, 2, b, 16 )
call MultiboardSetItemStyleBJ( udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 2, b, "|c00A3B7F5Teame Kills(50 to win):|r" )
set b = b + 1
// Empires
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, udg_Color[6] + "|c00FF80FFEast|r")
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[20]) ) )
set udg_Mult[6] = b
set b = b + 1
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, udg_Color[12] + "|c00000000West|r")
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[21]) ) )
set udg_Mult[12] = b
call MultiboardDisplayBJ( true, udg_MBoard )
call MultiboardDisplayBJ( false, udg_MBoard )
call MultiboardDisplayBJ( true, udg_MBoard )
call MultiboardMinimizeBJ( false, udg_MBoard )
call MultiboardMinimizeBJ( true, udg_MBoard )
endfunction
//===========================================================================
function InitTrig_KillboardCreate takes nothing returns nothing
set gg_trg_KillboardCreate = CreateTrigger( )
call TriggerRegisterTimerEventSingle( gg_trg_KillboardCreate, 0.05 )
call TriggerAddAction( gg_trg_KillboardCreate, function Trig_Multiboard_Actions )
endfunction
function Trig_we_Func001001001 takes nothing returns boolean
return ( GetPlayerSlotState(Player(0)) == PLAYER_SLOT_STATE_PLAYING )
endfunction
function Trig_we_Func001001002 takes nothing returns boolean
return ( GetPlayerController(Player(0)) == MAP_CONTROL_USER )
endfunction
function Trig_we_Func001001 takes nothing returns boolean
return GetBooleanAnd( Trig_we_Func001001001(), Trig_we_Func001001002() )
endfunction
function Trig_we_Func001002 takes nothing returns boolean
return ( GetPlayerSlotState(Player(0)) == PLAYER_SLOT_STATE_LEFT )
endfunction
function Trig_we_Conditions takes nothing returns boolean
if ( not GetBooleanOr( Trig_we_Func001001(), Trig_we_Func001002() ) ) then
return false
endif
return true
endfunction
function Trig_we_Actions takes nothing returns nothing
endfunction
//===========================================================================
function InitTrig_KDDefault takes nothing returns nothing
set gg_trg_KDDefault = CreateTrigger( )
call TriggerAddCondition( gg_trg_KDDefault, Condition( function Trig_we_Conditions ) )
call TriggerAddAction( gg_trg_KDDefault, function Trig_we_Actions )
endfunction
function Trig_Refresh2_Actions takes nothing returns nothing
local integer a = 1
local integer b = 1
// String 1
loop
exitwhen a > 3
call MultiboardSetItemWidthBJ( udg_MBoard, a, 1, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, 1, false, false )
call MultiboardSetItemWidthBJ( udg_MBoard, a, 2, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, 2, false, false )
set a = a + 1
endloop
call MultiboardSetItemWidthBJ( udg_MBoard, 2, 1, 16 )
call MultiboardSetItemStyleBJ( udg_MBoard, 2, 1, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 2, 1, "|c00A3B7F5Time ("+I2S(udg_M_Min)+":"+I2S(udg_M_Sec)+")|r" )
call MultiboardSetItemWidthBJ( udg_MBoard, 1, 2, 10 )
call MultiboardSetItemStyleBJ( udg_MBoard, 1, 2, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 1, 2, "|cFFFE8A0E Sentinel|r" )
set b = 3
// Auril
set a = 0
loop
exitwhen a > 5
if ( GetPlayerSlotState(Player(a)) == PLAYER_SLOT_STATE_PLAYING ) or ( GetPlayerSlotState(Player(a)) == PLAYER_SLOT_STATE_LEFT ) then
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemIconBJ( udg_MBoard, 1, b, udg_Iconki_DlyBorda[a+1] )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, true )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, ( udg_Color[a+1] + GetPlayerName(Player(a)) ))
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[a+1]) ))
call MultiboardSetItemWidthBJ(udg_MBoard, 3, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 3, b, (I2S(udg_Deaths[a+1]) ) )
set udg_Mult[a+1] = b
set b = b + 1
endif
set a = a + 1
endloop
set a = 1
loop
exitwhen a > 3
call MultiboardSetItemWidthBJ( udg_MBoard, a, b, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, b, false, false )
set a = a + 1
endloop
// Goharol
call MultiboardSetItemWidthBJ( udg_MBoard, 1, b, 10 )
call MultiboardSetItemStyleBJ( udg_MBoard, 1, b, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 1, b, "|cFF4E2A04 Scourge|r" )
set b = b + 1
set a = 6
loop
exitwhen a > 11
if ( GetPlayerSlotState(Player(a)) == PLAYER_SLOT_STATE_PLAYING ) or ( GetPlayerSlotState(Player(a)) == PLAYER_SLOT_STATE_LEFT ) then
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemIconBJ( udg_MBoard, 1, b, udg_Iconki_DlyBorda[a+1] )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, true )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, ( udg_Color[a+1] + GetPlayerName(Player(a)) ))
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[a+1]) ) )
call MultiboardSetItemWidthBJ(udg_MBoard, 3, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 3, b, (I2S(udg_Deaths[a+1]) ) )
set udg_Mult[a+1] = b
set b = b + 1
endif
set a = a + 1
endloop
call TriggerSleepAction( 0.10 )
set a = 1
loop
exitwhen a > 3
call MultiboardSetItemWidthBJ( udg_MBoard, a, b, 0.01 )
call MultiboardSetItemStyleBJ( udg_MBoard, a, b, false, false )
set a = a + 1
endloop
call MultiboardSetItemWidthBJ( udg_MBoard, 2, b, 16 )
call MultiboardSetItemStyleBJ( udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ( udg_MBoard, 2, b, ( "|c00A3B7F5Team kills(" + ( I2S(udg_Nugno_Kills) + " for win)" ) ) )
set b = b + 1
// Empires
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, udg_Color[6] + "|cFFFE8A0ESentinel|r")
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[13]) ) )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, false, false )
set udg_Mult[6] = b
set b = b + 1
call MultiboardSetItemWidthBJ(udg_MBoard, 1, b, 10.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 1, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 1, b, udg_Color[12] + "|cFF4E2A04Scourge|r")
call MultiboardSetItemWidthBJ(udg_MBoard, 2, b, 3.00 )
call MultiboardSetItemStyleBJ(udg_MBoard, 2, b, true, false )
call MultiboardSetItemValueBJ(udg_MBoard, 2, b, (I2S(udg_Kills[14]) ) )
call MultiboardSetItemStyleBJ(udg_MBoard, 3, b, false, false )
set udg_Mult[12] = b
endfunction
//===========================================================================
function InitTrig_KillboardRefresh takes nothing returns nothing
set gg_trg_KillboardRefresh = CreateTrigger( )
call TriggerRegisterTimerEventPeriodic( gg_trg_KillboardRefresh, 0.50 )
call TriggerAddAction( gg_trg_KillboardRefresh, function Trig_Refresh2_Actions )
endfunction
function Trig_Echo_Slam_Conditions takes nothing returns boolean
return GetSpellAbilityId() == 'A014'
endfunction
function Echo_Group takes nothing returns boolean
return ( IsUnitEnemy(GetFilterUnit(), GetOwningPlayer(GetTriggerUnit())) == true )
endfunction
function Trig_Echo_Slam_Actions takes nothing returns nothing
local location l = GetUnitLoc(GetTriggerUnit())
local group g
local unit u
local unit v
call TriggerSleepAction(.25)
set g = GetUnitsInRangeOfLocMatching(500, l, Condition(function Echo_Group))
loop
set u = FirstOfGroup(g)
exitwhen u ==null
call GroupRemoveUnit(g,u)
set v = CreateUnit(GetOwningPlayer(GetTriggerUnit()),'n000',GetUnitX(u), GetUnitY(u), bj_UNIT_FACING)
call SetUnitAbilityLevelSwapped( 'A015', v, GetUnitAbilityLevelSwapped('A014', GetTriggerUnit()) )
call IssueImmediateOrder(v,"fanofknives")
call UnitApplyTimedLife(v,'BTLF',1.00)
endloop
call RemoveLocation(l)
set l = null
call DestroyGroup(g)
set g = null
set v = null
endfunction
//===========================================================================
function InitTrig_EchoSlam_Echoes takes nothing returns nothing
set gg_trg_EchoSlam_Echoes = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_EchoSlam_Echoes, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call TriggerAddCondition( gg_trg_EchoSlam_Echoes, Condition( function Trig_Echo_Slam_Conditions ) )
call TriggerAddAction( gg_trg_EchoSlam_Echoes, function Trig_Echo_Slam_Actions )
endfunction