Starting Hero Spawn has random spawn in different regions

ss501maku

New Member
Reaction score
0
:banghead:Starting Hero Spawn has random spawn in different regions:(

How to create hero triggers, to each playable player and that player own hero in map initiation has can spawn in random region or in different region and i have 16 region (spawn area) in my map,

and every time players hero has die, he can also revive in random different region (16 region)

my map version is free for all for 12 players. every player die, has 10seconds time resurection, and can respawn in different region in map.

tnx for help and kindness also world editor:)
 

Ashlebede

New Member
Reaction score
43
The most simple way to do this :

Trigger:
  • //Hand-written
    • Events
      • Map Initialization
    • Conditions
    • Actions
      • Set SpawnRegions[0] = HeroRegion0 <gen>
      • Set SpawnRegions[1] = HeroRegion1 <gen>
      • Set SpawnRegions[2] = HeroRegion2 <gen>
      • -------- And so on... --------
      • Set loc = Center of SpawnRegions[(Random integer from 0 to 15)]
      • Unit - Create [...] at loc
      • Custom Script : call RemoveLocation(udg_loc)


Setting a point variable and removing it later using custom script to clear memory leaks. Most low-level gameplay maps don't clear leaks at all, so it is sometimes unnecessary. However, it's better programming practices and it reduces lag in the long run.
 

ss501maku

New Member
Reaction score
0
The most simple way to do this :

Trigger:
  • //Hand-written
    • Events
      • Map Initialization
    • Conditions
    • Actions
      • Set SpawnRegions[0] = HeroRegion0 <gen>
      • Set SpawnRegions[1] = HeroRegion1 <gen>
      • Set SpawnRegions[2] = HeroRegion2 <gen>
      • -------- And so on... --------
      • Set loc = Center of SpawnRegions[(Random integer from 0 to 15)]
      • Unit - Create [...] at loc
      • Custom Script : call RemoveLocation(udg_loc)


Setting a point variable and removing it later using custom script to clear memory leaks. Most low-level gameplay maps don't clear leaks at all, but pretty much all big projects do.


okay thanks! i'll try this one. . :thup:
 

ManyTimes

I'm so lonesome I could cry...
Reaction score
293
What is "another easy trigger for all players"?

Details.

A "revive" trigger for all players?

Code:
Revive
    Events
        Unit - A unit Dies
    Conditions
        ((Triggering unit) is A Hero) Equal to True
    Actions
        Wait 5.00 seconds
        Set p = (Center of region[(Random integer number between 1 and 16)])
        Hero - Instantly revive (Triggering unit) at p, Show revival graphics
        Custom script:   call RemoveLocation(udg_p)
Same procedure
 
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