Thread: grab
View Single Post
  #9  
Old 08-27-2007, 09:49 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
Quote:
Originally Posted by DustyPorViva View Post
Well that's easy to stop:
PHP Code:
function onKeypressed() {
  if (
keydown(6))  {
    if (
temp.keydown==false) {
      
triggeraction(player.x+1.5+vecx(player.dir)*2,player.y+2.5+vecy(player.dir)*2,"grabbed",parameters...);
      
temp.keydown=true;
    }
  } else 
temp.keydown=false;

That wouldn't be needed, since that event woulød only be triggered when the player presses a key
(PS: this. instead of temp.)
__________________
Reply With Quote