![]() |
Need help dealing with functions.
Okay, I didnt really know what to title this topic, but anywho..
I have a skill that reduces damage taken if the opposing player attempts to attack from a particular direction. However, the damage script is of course in a separate weapon. So heres where my problem comes in.. I need to know how to go about interrupting the function that normally processes damage, and instead check to see if they have the skill and if the conditions apply, then to go back to the function that was interrupted, process the results and finally adjust the final damage results accordingly. Instead of, you know, just stamping the skill code into the damage code and checking to see if the player has obtained the skill by checking a flag. Any tips? |
If you want to do it the function way and have the damage script to ask the skill weapon each time if they have the skill then in the skill weapon, mark the function as public (this allows it to be called from other scripts but will only work clientside->clientside or serverside->serverside):
PHP Code:
PHP Code:
PHP Code:
PHP Code:
|
Thanks, I'll play around with that :)
|
All times are GMT +2. The time now is 11:23 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.