| Mirage Source http://www.miragesource.net/forums/ |
|
| Movement Tiredness http://www.miragesource.net/forums/viewtopic.php?f=210&t=76 |
Page 1 of 1 |
| Author: | grimsk8ter11 [ Thu Jun 01, 2006 10:10 pm ] |
| Post subject: | Movement Tiredness |
Tutorial for adding in movement (tiredness) for when u move and fight. It lowers SP and then regens. its upto you how u expand on it (eg. u might not want this for walking). Actual combat effectiveness or whatever with low movement is upto you to do. Im using the variable SP for movement which is already set up for SP regenning. Server Side in ModGameLogic put this in Sub AttackPlayer AND into Sub AttackNpc Code: ' Drop the SP If GetPlayerSP(Attacker) > 0 Then Call SetPlayerSP(Attacker, GetPlayerSP(Attacker) - 1) Call SendSP(Attacker) End If Then (still in ModGameLogic) put this in Sub PlayerMove Code: If Moved = YES Then
'reduce SP by 1 when moving ' Drop the SP If GetPlayerSP(Index) > 0 Then Call SetPlayerSP(Index, GetPlayerSP(Index) - 1) Call SendSP(Index) End If End If I hope this is good enough for a tutorial. Apologies if not. I got some help from dave and anthony - so its not totally all mine. although i did good! and all the extra stuff (i didnt put in here - unless ppl request an expansion) is mine wooooooooot! Ive also added this into casting spells and added a bar under the sprite for movement (tiredness), and movement affects your combat and spell casting power. if you would like to see this code then let me know and ill gladly post it. works great woot! |
|
| Author: | lordgivemick [ Fri Dec 22, 2006 12:19 am ] |
| Post subject: | |
yes i now this is old but i have a comment for all the peopel out there. This is genius this will make it so people have a better and more playable reality. It will make it like "what he siad above where you get tired when you atk or walk run". however you want to modify it to work for ,but thats up to you just think reality |
|
| Page 1 of 1 | All times are UTC |
| Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |
|