Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #9  
Old 09-08-2010, 01:02 PM
Raeiphon Raeiphon is offline
I never asked for this.
Join Date: Jun 2005
Posts: 855
Raeiphon is on a distinguished road
PHP Code:
function onWeaponFired() {
  if (
this.out) {
    
this.doAttack();
  } else {
    
this.drawGun();
  }

Handle this.out in drawGun(); and your projectile function in doAttack(); and you're right as rain. I normally handle gani replacement within such scripts and ensuring that the weapon variables are properly set/carried across uses in functions like this at the same time. This may seem a bit sparse, but I'm sure you're capable of toggling a boolean value within a function without being told how to do it.

You really don't need to use a timeout for this.
__________________

I hope for nothing. I fear nothing. I am free.
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 01:22 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.