Terrain and Special Effects Snippets

Status
Not open for further replies.

zll7

New Member
Reaction score
17
Very easy trigger...but can be very useful. And it makes every game with the same map a little diffrent :D

Code:
Spawn Trees
    Events
        Time - Every X seconds of game time
    Conditions
    Actions
        Destructible - Create a Summer Tree Wall at (Random point in (Playable map area)) facing (Random angle) with scale 1.00 and variation 0

Code:
stop trees
    Events
        Time - Elapsed game time is x seconds
    Conditions
    Actions
        Trigger - Turn off Spawn Trees <gen>
 

Shadowy Fear

I have returned
Reaction score
44
If you have a volcano, hell, or some other fire related area in your map, and want to give it some ambience, create a region over it and do:

Code:
E: every (interger A) seconds
C: N/A
A: create special effect at random point in region using flame strike

This trigger creates a flame effect over a point, to simulate a fiery burst of ... fire :p. You could alternately pick a random point, and then set that point to a point variable, and THEN damage all units around it. Or just have a dummy unit cast a spell there. Your choice :D. Another option is to mess with the art, to create blizzards and lightning storms :)
 

xPheRe

New Member
Reaction score
43
Random weather

I read a while ago about someone needing random weather stuff.
I finally found how to do it, it's only a beggining but it does the work.

For this uses, the map has four variables:

Weather - Current weather (0=Sunny, 1=Cloudy, 2=Rainy, 3=Lightning)
mmHg - Current air preasure
mmHgvector - This value adds to the mmHg every second
mmHginc - This value adds to the mmHgvector every second, then recalculates itself by adding some random values

I hope it could be useful for anyone
 

Attachments

  • xph.RandomWeather.w3x
    31.9 KB · Views: 725

Andrewgosu

The Silent Pandaren Helper
Reaction score
716
A few simple functions - timed special effects.

JASS:
function AddSpecialEffectTimed takes string modelName, real x, real y, real duration returns nothing
    local effect e = AddSpecialEffect( modelName, x, y )
    
    call PolledWait(duration)
    call DestroyEffect(e)
    set e = null
endfunction


JASS:
function AddSpecialEffectLocTimed takes string modelName, location whichLoc, real duration returns nothing
    local effect e = AddSpecialEffectLoc( modelName, whichLoc )
    
    call PolledWait(duration)
    call DestroyEffect(e)
    set e = null
endfunction


JASS:
function AddSpecialEffectTargetTimed takes string modelName, widget targetWidget, string attachPointName, real duration returns nothing
    local effect e = AddSpecialEffectTarget( modelName, targetWidget, attachPointName )
    
    call PolledWait(duration)
    call DestroyEffect(e)
    set e = null
endfunction
 
Status
Not open for further replies.
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top