Gamestudio Links
Zorro Links
Newest Posts
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, ozgur), 1,415 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19055 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Animation does not play #190291
03/25/08 18:06
03/25/08 18:06
Joined: Aug 2004
Posts: 122
A small town near Cologne
E
Elitegunner Offline OP
Member
Elitegunner  Offline OP
Member
E

Joined: Aug 2004
Posts: 122
A small town near Cologne
I have a script here for my model and the animation wich plays without a script but not with one,
problem is that i need to apply an material function!

the script is the follow:

Code:

action my_model
{
my.material = mat_alphatest;
my.skill1 += 3*time_step;
if (my.skill1 > 100) my.skill1 -= 100;
ent_animate(me,"Anim",my.skill1,ANM_CYCLE);
wait(1);

}



when i try to run it i get follow error:

Code:

< (my.skill1>100)my.skill1-=100>
mymodel.wdl 5:0 (): Syntax error - - missing semicolon? my.skill1-=100
.
Script error
Engine shutdown



the semicolon is there, i marked it red above in the code.
So whats the problem?

i'm using A6 commercial v6.60

Re: Animation does not play [Re: Elitegunner] #190292
03/25/08 18:21
03/25/08 18:21
Joined: Dec 2006
Posts: 1,086
Queensland - Australia
Nidhogg Offline
Serious User
Nidhogg  Offline
Serious User

Joined: Dec 2006
Posts: 1,086
Queensland - Australia
Quote:

I have a script here for my model and the animation wich plays without a script but not with one,
problem is that i need to apply an material function!

the script is the follow:

Code:

action my_model
{
my.material = mat_alphatest;
my.skill1 += 3*time_step;
if (my.skill1 > 100) my.skill1 -= 100;
ent_animate(me,"Anim",my.skill1,ANM_CYCLE);
wait(1);

}



Maybe try this this.

Code:

action my_model
{
my.material = mat_alphatest;
my.skill1 += 3*time_step;
if (my.skill1 > 100) {my.skill1 -= 100;}
ent_animate(me,"Anim",my.skill1,ANM_CYCLE);
wait(1);

}




Windows XP SP3
Intel Dual Core CPU: E5200 @ 2.5GHz
4.00GB DDR3 Ram
ASUS P5G41T-M LX
PCIE x16 GeForce GTS 450 1Gb
SB Audigy 4
Spyware Doctor with AntiVirus
Re: Animation does not play [Re: Nidhogg] #190293
03/25/08 18:25
03/25/08 18:25
Joined: Aug 2004
Posts: 122
A small town near Cologne
E
Elitegunner Offline OP
Member
Elitegunner  Offline OP
Member
E

Joined: Aug 2004
Posts: 122
A small town near Cologne
no errors anymore, but the animation still shows only one frame and does not play.

btw: its an point-animation, not bones.

Last edited by Elitegunner; 03/25/08 18:35.
Re: Animation does not play [Re: Elitegunner] #190294
03/25/08 18:33
03/25/08 18:33
Joined: Dec 2006
Posts: 1,086
Queensland - Australia
Nidhogg Offline
Serious User
Nidhogg  Offline
Serious User

Joined: Dec 2006
Posts: 1,086
Queensland - Australia
Maybe look in the manual under ent_animate() will help you further.


Windows XP SP3
Intel Dual Core CPU: E5200 @ 2.5GHz
4.00GB DDR3 Ram
ASUS P5G41T-M LX
PCIE x16 GeForce GTS 450 1Gb
SB Audigy 4
Spyware Doctor with AntiVirus
Re: Animation does not play [Re: Nidhogg] #190295
03/25/08 18:50
03/25/08 18:50
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Code:

action my_model
{
my.material = mat_alphatest;
while(1){
my.skill1 += 3*time_step;
if (my.skill1 > 100) {my.skill1 -= 100;}
ent_animate(me,"Anim",my.skill1,ANM_CYCLE);
wait(1);
}
}



you need a loop


3333333333
Re: Animation does not play [Re: Quad] #190296
03/25/08 19:44
03/25/08 19:44
Joined: Aug 2004
Posts: 122
A small town near Cologne
E
Elitegunner Offline OP
Member
Elitegunner  Offline OP
Member
E

Joined: Aug 2004
Posts: 122
A small town near Cologne
that works, but the animation is too fast, even with 1*time_step

Re: Animation does not play [Re: Elitegunner] #190297
03/25/08 19:54
03/25/08 19:54
Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,210
İstanbul, Turkey
try 1*time_step/100 or something.


3333333333
Re: Animation does not play [Re: Quad] #190298
03/25/08 19:56
03/25/08 19:56
Joined: Aug 2004
Posts: 122
A small town near Cologne
E
Elitegunner Offline OP
Member
Elitegunner  Offline OP
Member
E

Joined: Aug 2004
Posts: 122
A small town near Cologne
omg i'm stupid ^^ my.skill1 += 0.08*time_step; that did it ^^


Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1