Thread: wa****
View Single Post
  #8  
Old 12-02-2009, 05:37 PM
Crow Crow is offline
ǝɔɐɹq ʎןɹnɔ
Crow's Avatar
Join Date: Dec 2006
Location: Germany
Posts: 5,153
Crow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond reputeCrow has a reputation beyond repute
Theoretically, it'd work, yes. But since you are bringing up gmaps, no. WasHit doesn't work on gmaps. At least it did not on Atlantis a couple months back. You can use something similar to this though:

PHP Code:
//#CLIENTSIDE
function onKeyPressed() {
  if (
player.freezetime || player.paused)
    return;
  
  if (!
keydown(5) || player.ani.name != "sword")
    return;
    
  
temp.tx player.1.5 vecx(player.dir) * 2;
  
temp.ty player.vecy(player.dir) * 2;
  
triggerAction(temp.txtemp.ty"Sword"player.account);

Old piece of code I've been using in the past. Triggers onActionSword(acc) in NPCs in range.
Reply With Quote