• Check out the results of the Techtree Contest #19!
  • 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.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

[Trigger] Setting a sky for one player

Status
Not open for further replies.
Setting a sky / skybox for one player

Hello everyone, i have one question!

how do i set a sky / skybox for one player with 'GetLocalPlayer' and without desync?

I've created a simple hero selection system with arrow keys for my map. If you press a key, the next hero will be shown as a preview with an unique sky.

The trigger i am currently using cause desync for sure.

  • Set PlayerNumber = ((Player number of (Triggering player)) - 1)
  • Custom script: if(GetLocalPlayer() == Player(udg_PlayerNumber)) then
  • Environment - Set sky to 'some sky'
  • Custom script: endif
someone told me this can be done with a text string? But i don't understand how and i didn't find a solution on the forums. Please help me =)
 
Nope. The JASS function for that is

native SetSkyModel takes string path returns nothing

The GUI counterpart for this does that except it gives u a list of presets. If u want to use an exact string,

Custom script: call SetSkyModel( "If This Path Is Invalid, The Game Will Desync" )
 
Alright, so i use:

  • Custom script: call SetSkyModel( "environment\Sky\FelwoodSky\FelwoodSky.blp" )
for a felwod sky?

nope..


Environment\\Sky\\FelwoodSky\\FelwoodSky.mdl

first of all, it always must be double slashed.

Also, capitalized letters count.

Also, the sky is not a texture it is a model. if u attempt to set it to a .blp, the game will crash regardless if its in a local block or not
 
Status
Not open for further replies.
Back
Top