Thread: Swimming
View Single Post
  #1  
Old 06-22-2008, 03:56 AM
xXziroXx xXziroXx is offline
Malorian
xXziroXx's Avatar
Join Date: May 2004
Posts: 5,289
xXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant futurexXziroXx has a brilliant future
Swimming

While trying to add a custom swim animation on Mythic, I noticed something annoying.

If it has more then one frame, it'll keep repeating the first frame over and over again. Why? My conclusion is that Graal keeps checking if the player is swimming, and if he is, it sets his animation to swim.gani.

PHP Code:
function onCreated() setTimer(.05);
function 
onTimeOut()
{
  echo(
"1:" SPC player.ani);
  
setAni("mythic_swim""");
  echo(
"2:" SPC player.ani);
  
setTimer(.05);

That input's a whole lot of this in your F2 log:

PHP Code:
1swim
2
mythic_swim
1
swim
2
mythic_swim
1
swim
2
mythic_swim
1
swim
2
mythic_swim 
Now it's time for my humble request to you, Stefan, and that is... can you pretty please make the client only set the players animation to default swim animation (replaceAni() friendly is a must!) while swimming if its NOT already that animation? I really want multi-frame swim gani without having to script a custom movement system.


EDIT: Forgot to mention that if you do replaceAni("swim", "yourswimani"); - it'll do the same thing and repeat the first frame of your animation over and over again.
__________________
Follow my work on social media post-Graal:Updated august 2025.
Reply With Quote