Duck AIFlag and onthinkscript

Bloodbane

Well-known member
1st question:
Is there any Flags or anything to set to force player into ducking state?
I want to create DUCKPAIN, DUCKBACKPAIN and DUCKBLOCKPAIN with script. Changing to those animations is easy however after animation end, player returns to standing or not ducking state

2nd question:
How does onthinkscript works? I've tried using it but it doesn't work the way I thought it should be
 
AFAIK for the first question, you can take a look at this. You can use both painscript and doattackscript for duckpain but I don't know about backpain and blockpain. Maybe you could (figure out to) modify it or make a copy (some copies?) for those scripts of your entities for playing specific pain reactions you mentioned.

Bloodbane said:
Changing to those animations is easy however after animation end, player returns to standing or not ducking state

Are you trying to make a player remain ducking (by holding down button) after s/he receives duckpain reactions?
 
Bloodbane, you should have a look here. It is documentation for the new method of property access for entities. Although the commands themselves are not yet released, the properties themselves are pretty much the same as always. The important part is that every last entity property is listed. EVERY property. If it isn't on that list, then it's another type of property (like a model property) or does not exist.

DC

 
Thanks for the replies guys :D
I'm going to test some of those properties later

maxman said:
Are you trying to make a player remain ducking (by holding down button) after s/he receives duckpain reactions?

Yes

[Some hours later]

Crashed the game. Those properties aren't available yet
 
Bloodbane Remember that we have different animations for duck? Like ducking and duckrise (I can't remember the proper names). http://www.chronocrash.com/forum/index.php?topic=3947.0 (I still need to add those animations to the manual, btw).

Have you tried to add those animations? Because by a logic point of view, after the "DUCKPAIN", the character should be reverted to the DUCK animation (which should be only the duck part). And still following the logic rule, DUCKPAIN its something the engine should care natively - I think "duck" is the most lacking area of all basic animations in OpenBOR.

I don't have time for now, but I will try to study the duck routine and see if I can add DUCKPAIN to the engine.
 
Are you using only duck anim with/for script? If not, do you have anims ducking and duckrise for anim duck? Since we have anim ducking and anim duckrise, anim duck should play a role of stay-still ducking of sprite(s)/frame(s) instead of starting to duck. So in the end, I think you shouldn't worry about scripting for anim duck.
 
Back
Top Bottom