| Mirage Source http://web.miragesource.net/forums/ |
|
| Smoother Walking http://web.miragesource.net/forums/viewtopic.php?f=210&t=3102 |
Page 1 of 1 |
| Author: | Rezeyu [ Sun Dec 02, 2007 8:54 pm ] |
| Post subject: | Smoother Walking |
I made this for Grave Silence, ported it into Crimson, and a side project; but forgot to ever type it up as a tutorial. Anyways, the current Mirage animates frames 0 and 1 for walking, and 0 for attacking. The smoother way Perfekt/Advo had, animated 0-1-2 then back to 0. This way animates 0-1-0-2 then abck to zero, since people's legs return the the middle before a step. Anyways, simple C&P. Find this in bltPlayer: Code: Select Case GetPlayerDir(Index) Case DIR_UP If (Player(Index).YOffset < PIC_Y / 2) Then Anim = 1 Case DIR_DOWN If (Player(Index).YOffset < PIC_Y / 2 * -1) Then Anim = 1 Case DIR_LEFT If (Player(Index).XOffset < PIC_Y / 2) Then Anim = 1 Case DIR_RIGHT If (Player(Index).XOffset < PIC_Y / 2 * -1) Then Anim = 1 End Select Replace with: Code: Select Case GetPlayerDir(Index) Case DIR_UP If (Player(Index).YOffset > 8) Then Anim = 1 If (Player(Index).YOffset > 16) Then Anim = 0 If (Player(Index).YOffset > 24) Then Anim = 2 Case DIR_DOWN Anim = 0 If (Player(Index).YOffset < -8) Then Anim = 1 If (Player(Index).YOffset < -16) Then Anim = 0 If (Player(Index).YOffset < -24) Then Anim = 2 Case DIR_LEFT Anim = 0 If (Player(Index).XOffset > 8) Then Anim = 1 If (Player(Index).XOffset > 16) Then Anim = 0 If (Player(Index).XOffset > 24) Then Anim = 2 Case DIR_RIGHT Anim = 0 If (Player(Index).XOffset < -8) Then Anim = 1 If (Player(Index).XOffset < -16) Then Anim = 0 If (Player(Index).XOffset < -24) Then Anim = 2 End Select And.. that's it. |
|
| Author: | Forte [ Tue Dec 04, 2007 6:36 pm ] |
| Post subject: | Re: Smoother Walking |
not sure if it's my source being modified but this doesn't really change the walking for me |
|
| Author: | Matt [ Tue Dec 04, 2007 7:03 pm ] |
| Post subject: | Re: Smoother Walking |
With permission from Robin, I can post his tut. I still have it, found it last night. It works a lot better than this method, as well as my method. |
|
| Author: | Robin [ Tue Dec 04, 2007 8:44 pm ] |
| Post subject: | Re: Smoother Walking |
You can send it to whoever you want privately, I just don't want it published on the forum. Don't ask why... no real reason xD |
|
| Author: | Matt [ Tue Dec 04, 2007 8:53 pm ] |
| Post subject: | Re: Smoother Walking |
Guess it won't be shared then. I'm not bothering with private messages. |
|
| Author: | RyanBlandin [ Mon Dec 31, 2007 6:45 pm ] |
| Post subject: | Re: Smoother Walking |
But if you had a special sprite for attacking that showed a sword or something wouldn't that sprite be included in the walking animation? |
|
| Author: | Rezeyu [ Mon Dec 31, 2007 9:01 pm ] |
| Post subject: | Re: Smoother Walking |
Then make the attacking frame frame 4. |
|
| Author: | Coke [ Fri Jan 04, 2008 11:16 pm ] |
| Post subject: | Re: Smoother Walking |
I had a really simple one that just had a standing frame, walking frame and attack frame for <- and ->, then a standing frame, two walking frames, and an attack frame for V and ^ Robin prolly has it, you can release mine if you want.. come to think of it, i think mine is pinched off someone else anyway xP |
|
| Page 1 of 1 | All times are UTC |
| Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |
|