Make bots replay real alien player movement to practice aim
botelhorui
Join Date: 2006-11-02 Member: 58192Members
in Modding
Hello there,
I don't know much about ns2 mapping/modding, but I am interested in making something that will be usefull to practice aim.
For example, I want to play as skulk, and record my movement in a certain map, using some command like "recordpath", then "stoppathrecord".
One scenario could be a marine player defending nanogrid in ns2_veil and then one skulk comes in walljumping really fast and the marine tries to kill the skulk. After killing the skulk or timeout it would show a message like "Trial complete. Accuracy: 13% "
To make it more interesting would be having many different paths going into nanogrid, that I guess would take some work to create.
Is this possible? Are guides and resource avaiable for this specific case?
Thank you
I don't know much about ns2 mapping/modding, but I am interested in making something that will be usefull to practice aim.
For example, I want to play as skulk, and record my movement in a certain map, using some command like "recordpath", then "stoppathrecord".
One scenario could be a marine player defending nanogrid in ns2_veil and then one skulk comes in walljumping really fast and the marine tries to kill the skulk. After killing the skulk or timeout it would show a message like "Trial complete. Accuracy: 13% "
To make it more interesting would be having many different paths going into nanogrid, that I guess would take some work to create.
Is this possible? Are guides and resource avaiable for this specific case?
Thank you
Comments
If this is possible we have a replay system for ns2^^
I wonder if an adhoc mod could make something good enough...
(1)Can a server mod add a callback to each server tick? Then it would record the position in a different thread. (2) Can you use threads in mods?
We would need to decide the permanent storage file format. I don't know the specifics of the NS2 packets contents, what do they contain, what does server do with it?
Something like a text file with each line:
<player_id><timestamp><list of pressed keys><mouse movement>
<player_id><timestamp><chat>
<server><timestamp><chat>
About replay, I assume that current ns2's bots use some algorightm to go to places, shoot/bite , and build. I think in training mode you only play agaisnt skulks, therefore assuming only that lifeform is supported. But! I was just some minutes ago in the game main screen and in the background of the Cave hive in ns2_mineshaft, and a Lerk gestated from an egg, got in the air and stayed there hovering.
To replay one would only need to read from the replay list of events:
Again, can you control bots in mods? like "press w for seconds" ?
Then at each server tick the mod would read the command from the replay.
One problem that I don't know enough, is about the stored timestamps. Does it make sense to save absolute time or relative time to the start? Or should the timestamp be the logical clock that counts the server ticks?
Should there be a clock synchronization between the running computer and the replay? Because the clock drift from the replay may be different from the current computer clock drift. And that would result in for example a bot turning to early and pressing w facing a wall.
I'm sure replays have been discussed a lot. But maybe devs now have different opinions.
Thanks
Why can't we? How do those games define entity paths?
//lunch brb
So somehow the scope of the "demo" would need to be limited and then replayed as AI.
http://forums.unknownworlds.com/discussion/comment/2265587/#Comment_2265587
Meanwhile I will try to install a bot mod I saw on workshop, and if it works I will give a look at the code.