• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Host Detection

Status
Not open for further replies.
Level 12
Joined
May 30, 2009
Messages
829
Jesus man, read the tutorial.

The player (Host) is automatically detected at map initialization, and then you can use that player for various purposes.

You can also have the function called again if the host leaves, since if the game is still going, there must be a player who can host, and that player will be detected.
 
Level 14
Joined
Mar 4, 2009
Messages
1,156
in the picture it says

Variable Type: Player (Player)

how did he do that (the orange part) ?

BTW:
i open my trigger editor

click on icon that has NameOfMyMap.w3x

i paste jass code down

Custom Script Code:
-JASS CODE

than i create this trigger

  • Untitled Trigger 001
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Custom script: Custom script: call GetHost()
i can enable/disable trigger but when i start the map test it fails

does it maybe fails because i don't know how to do Variable Type: Player (Player)?

and i did do this variable

Variable Name: "Host"
Variable Type: Player
 
Level 15
Joined
Aug 11, 2009
Messages
1,606
Level 17
Joined
Jun 12, 2007
Messages
1,261
Status
Not open for further replies.
Top