How does the engine collect/record player behaviour?

So I’m looking for an engine I can use for a project with game AI, and need to know how/whether Unity records player behavior. I would like to know especially whether it can do so ‘on the fly’, so that I can modify game parameters during playtime?

What do you mean by "record player behaviour"? You mean like every action they do is recorded? No, unity doesn't do that unless you tell it to, through SCRIPTING. You need to MAKE a script(a piece of code) that does that. Also, Yes you can do AI, If you spend enough time...

I mean is it possible/supported by the game engine itself to record what they do. For instance, in a tactical turn based game how a player's units were arranged, in an fps how the player is moving/where they are located, or in a racing game how far ahead of the rest of the racers they are, how much faster they're travelling, etc.

1 Answer

1

As @dvidunis mentioned, you can absolutely write scripts to gather all kinds of player information. The type of information available is basically limitless - the state of just about everything can be accessed from script.

You probably want to start out looking at the documentation for Transform, which gives you information about location / orientation in space: Unity - Scripting API: Transform

You can also access a lot of information about (or even through) the components attached to a player, or any other object. For instance, you can attach a collider to a player and perform actions (like logging) when the collider receives events (see the Messages section): Unity - Scripting API: Collider