View Single Post
  #1  
Old 05-12-2008, 06:37 AM
wild8900 wild8900 is offline
Mr. Brightside
wild8900's Avatar
Join Date: Dec 2005
Posts: 418
wild8900 is an unknown quantity at this point
Send a message via MSN to wild8900
Triggeraction: Class NPC to Level NPC

Im having problems with this trigger action. Im making a script that places a block and when this block is on top of another npc (a floor switch), it triggers the switch. For some reason the RC says there arent enough params when I test it. Its strange...

Heres the block's trigger action (in an onCreated function)
PHP Code:
//#CLIENTSIDE
function onCreated() {
  
triggeraction(player.x+vecx(player.dir)*2,player.y+vecx(player.dir)*2,"Block",0);

And here's the switch's action (Inside the level).
PHP Code:
//#CLIENTSIDE
function onactionBlock() {
  
this.on=1;
  
setimg buttonpressed.png;

Reply With Quote