problem with ent_animate

Posted By: Nowherebrain

problem with ent_animate - 06/15/09 22:02

Has ent_animate changed? I am having problem with a very simple piece of code....

it does not animate even with tried and true models like the warlock...

var anim_cycle;

action guss()
{

player = my;
set(my,SHADOW);
my.material = mat_alphatest;

while(1)
{

ent_animate(my,"run",anim_cycle,ANM_CYCLE);
anim_cycle += 5 * time_step;
anim_cycle %= 100;

my.pan -= mouse_force.x + mouse_force.x;

wait(1);
}
}

..this is very simple, but does not work???? what am I missing?
Posted By: MrGuest

Re: problem with ent_animate - 06/16/09 00:48

no problems here... unless i place a bone in the model? then ceases all vertex animations

using
Code:
	set(my, SHADOW);
	
	while(me){
		
		ent_animate(me, "walk", my.skill1, ANM_CYCLE);
		my.skill1 += 5 * time_step;
		my.skill1 %= 100;
		
		my.pan = mouse_force.x * 2;
		
		wait(1);
	}


other things i can think of (sorry to go through the basics, but the fresh pair of eyes etc...):
you haven't attached the action
the frames are named "run 1" instead of "run1"
you've given the actor a global var for anim_cycle, and too many entities are making it 0 again (yes i'm clutching at straws) laugh
Posted By: Nowherebrain

Re: problem with ent_animate - 06/16/09 06:46

Yes, of course! the global....thanks..I will go change it....
Posted By: Nowherebrain

Re: problem with ent_animate - 06/16/09 06:55

Well I double checked and it was not the global, it seems to work fine with a global, but sure enough "show bones" was unchecked in MED....problem solved. Thanks.
© 2024 lite-C Forums