Yes, we could write it that way, but that would be wrong.
I have no idea how you get to 10 game turns from 500 divided by 1000 (based on your function).
Well, I’ve missphrased that bit as I tried to keep it simple and later deceided to be a bit more specific…
As far as I can tell, correct is:
A turn ends when all move points are spent.
And what I tried to say is:
A “turn”, equal to an ingame second, passes after the player used up his, which usually is 100 “move points” (as in 100 speed and 100 base move cost = 100) for a default player.
My fault. I’ll remove that one, that’s just complicating it more for no real gain.
Uhm, no. This is the opposite of what I’ve described, actually.
I don’t know what you mean with “teleported” and “capture”, as neither is teleporting.
Based on my description: If they can move before you can move, and are standing next to you, and want to move to your tile, than they attack. If you have enough points to move, you move first, then the Zombie to the tile you stood previously.
I can go in and check the code how it’s really done if you want, but I’m not sure if that time would be well spent, as I expect my math/explanation would hold up with a high probability, with only minor changes to the sequence and things that I’ve left out because of simplicity. And I doubt it would explain what’s going on with the faster speed of the Zombies.
However, you could check it yourself if you want to…
The relevant code parts that I know about are:
Main function and best bet at finding the right sequence is do_turn() in game.cpp, as well as monmove().
The monster’s actions can be found in the function move() and attack_at(…) in monmove.cpp.
I’m not sure where the player moves are located, I’d think they are in the character.cpp or player.cpp file, but I can’t find them right now…