View Single Post
  #5  
Old 05-30-2014, 10:33 PM
callimuc callimuc is offline
callimuc's Avatar
Join Date: Nov 2010
Location: Germany
Posts: 1,015
callimuc is a splendid one to beholdcallimuc is a splendid one to beholdcallimuc is a splendid one to beholdcallimuc is a splendid one to beholdcallimuc is a splendid one to behold
Ah I now get it. You'd need to make a player class (like a health class) to check what the players z value is (inside the onActionLighthurt()) and control any further stuff from there on.

PHP Code:
function onActionLighthurt() {
  if (
player.z in |-33|) { //players Z value goes from -3 to 3
    //same as if (player.z >= -3 && player.z <= 3)
    //Do your stuff inside here
    
player.chat "'eyy";
  }

for the triggerAction() you'd only need to do triggeraction(player.x + 1.5 + vecx(player.dir) * 4, player.y + 2 + vecy(player.dir) * 4, "Lighthurt", player.dmg); now
__________________
MEEP!
Reply With Quote