Piccolo
Well-known member
Yeah obviously but it's just a workaround, or a "hack" if you prefer.Updated:
After adjusting the delays and set(data, "switchFrame", X); to lower number,
it is working fine in Build 4.0 without the code below
Code:@script if(frame > 0) daimaoCancel(); @end_script
Because you changed this the cancel system no longer works properly. You basically disabled the switchFrame feature of this cancel system, which enforce that the cancel doesn't happen until said switchFrame, even if the cancel is registered before (using key script).
Basically you will no longer get "smooth" cancels with this workaround.
So something probably has changed with this from 3.X to 4.X. You can test this using this simple script in an entity header :
Code:
@script
drawstring (10, 60, 3, "This is working");
@end_script
OpenBOR 3.X will accept it, but not 4.X. Now I'm aware it might have never been intended to work in 3.x even if it did, but it was actually a very nice feature for stuff like this.
So in the meantime, @Bruce, the real workaround is to put the "problematic" code in the animationscript main function. But beware if you also use this animation script for entity that don't support daimao cancel.
EDIT : you might also need to retrieve "frame" value yourself, because with inline animation script the engine does it automatically.
Code:
main(){
...
int frame = getlocalvar("frame");
if(frame > 0) daimaoCancel();
...
}
Last edited: