OpenBOR v3.0 Build 4273 (Windows/Wii/Android)
http://www.mediafire.com/file/z6t6kd48mn1sbiv/OpenBOR_v3.0_Build_4273.rar
play/rec mode finally works!!
- play/rec mode (script version)
usage:
to rec: recordinputs(1,"","myrec.inp");
to play: recordinputs(2,"","myrec.inp");
to stop: recordinputs(0);
to free: recordinputs(3);
useful for attract mode for example.
for example write in levelscript:
recordinputs(1,"","myrec.inp");
if(playerkeys(0,1,"esc")) { recordinputs(0); }
play at level..
press "esc" to terminate the rec.
then change recordinputs(1,"","myrec.inp"); in recordinputs(2,"","myrec.inp"); to test and play the recorder gameplay!
how you see recordinputs() use a first value param.
0 to stop the rec/play
1 to rec
2 to play
3 to free (dont worry when you use 0 you free the buffer too). the 3 param is not really useful.
example recordinputs(1,"","myrec.inp"); is to rec
use getrecordingstatus()to get the gameplay status 0 or 1 or 2
NOTE: you need for a deterministic game and so is not allowed a custom seed.
If you change anything in your mod or change the engine version you need to re-record the gameplay!!
I raccomanded you to disable all Keys duing the gameplay with new playerproperty(pindex,"disablekeys") excluded Keys to stop the gameplay.
then reactivate the Keys.
to disable Keys just changeplayerproperty(pindex,"disablekeys",openborconstant("FLAG_START")+openborconstant("FLAG_ATTACK")); for example
to re-enable Keys just: changeplayerproperty(pindex,"disablekeys",0);
- improved rand32() func
- added "destx", "destz" in entityproperty(). destx and destz are the the destination position for A.I. after a think. It's useful for custom AI (example to reach a ladder)