Frontpage Forums MAPPING HANGOUT MAPPING NICE-TO-KNOWS Sweet WAC commands | Damage zones & Healing station Reply To: Sweet WAC commands | Damage zones & Healing station
  • Inactive
    January 3, 2018 at 16:53 #2375

    Code examples above were generated by N.I.L.E.! Bad code and poor examples, no offense.

    First example is not how you set up a mission zone at all! Players are free to go anywhere – except within 5 metres of ssn_object1! No good!

     

    Assume player starts at X heading for Alpha PSP. Use for example the ssn for alpha as follows to set up your first mission zone if you do not want players to move too far away from objective Alpha:

    if eq(v1,0) then  //use conditions, no need to fire PLOOP every second throughout the entire mission!

    ploop

    if !ssnnearssn(player,133519,560) then  //if  not within 560 metres of alpha player will INEXPLICABLY(!) loose health

    consol(“<cFF0000>*** STAY IN THE MISSION ZONE ***<-co>”)  //and get a WARNING!!! IMPORTANT DETAIL!

    wave(“alarm1.wav”) //and maybe a sound to trigger player attention

    ssnaddhp(player,-10)

    endif

    end

    endif

     

    Now let the player complete an objective to unlock the next zone. Something like if ssndead(target) ENTER set(v1,1) endif. Now you can use v1,1 to set up the next mission zone while the first mission zone is deactivated! Much better. Apart from the inexplicable part. I don’t like mission zones much. No creativity! The only good part is setting up a variable to monitor mission progress. I don’t think soldiers start bleeding spontaneously if they are too far from Berlin.

     

     

    Second example immediately restores all health. Players will also be virtually immortal within 10 meter radius of PSP!! Not good at all!

    Why not create a MASH or a MESS? You can use beds or chairs respectively for players to heal themselves. It should be VERY OBVIOUS to use objects this way!!!

    SWEET WAC:

    //MESS wac by Shemihazah
    if !ssnride(134058) and !ssnride(134059) enter //ssn of beds or chairs

    set(v7,0)

    endif

    if ssnride(134058) then   //ensure following ploop only fires if a player is on the bed or chair!

    ploop

    if ssnonssn(player,134058) then

    ssnaddhp(player,3)

    set(v7,1)

    ssnwave(134058,”medbeat1.wav”,25)

    endif

    end

    endif

    if ssnride(134059) then

    ploop

    if ssnonssn(player,134059) then

    ssnaddhp(player,3)

    set(v7,1)

    ssnwave(134059,”medbeat1.wav”,25)

    endif

    end

    endif

    if eq(v7,1) enter

    consol(“<cDD10FF>Healing…<-co>”)

    endif

     

    Last but not least:

    Do not punish players for your lack of creativity! Think of a solution, mission zones are a work around – at best!

Latest 10 Maps

AW2 – Cry Havoc

AW2 – Angus : White Coast Part 1

AW2 – And Then Came The Morning

AW2 – A-7 BOHICA

AW2 – A Walk To The Devil

Rachetes Mappack (18 AW2 maps)

Red Sparrow Mappack (13 AW2 maps)

-Tof- Lunda Tribute Mappack (17 AW2 maps)

Viper 77 Mappack (13 AW2 maps)

Hardmaps AW2 Mappack #2 (17 maps by HmS Shadowman)

Recently Active Members

Profile picture of -ToF-Oldie
Profile picture of Andrey_Berg
Profile picture of Walker*|*
Profile picture of JCS.Wolfe.GEKO
Profile picture of CmdrKaBoom
Profile picture of TO77
Profile picture of sparky52
Profile picture of Captain
Profile picture of Ennio PG
Profile picture of Red Dog
Profile picture of Avble
Profile picture of korzekwa
Profile picture of Coopwarriors
Profile picture of M Jay Blake
Profile picture of Storm_GEKO

Log In

Username:

Password:


Lost password? | Register