MP Player Spawner

MP Player Spawner is the soul of getting a players character into the game, spawned with any components in the Components to Add list, which is where you should add the MPPlayerStats or MPDMPlayerStats component, depending on game mode. This is where modularity comes intosome seriously useful effect. We can add components and prefabs at spawntime, and per remote or local player, you can note in the demo only the remote players character requires a nametag prefab, so we add it at runtime when the player is spawned. MPPlayerSpawner will sort out what needs to be assigned to who on what machine relevant to which list the component or prefab is placed in.

Default Character

This is the character prefab that should be spawned in the case of no MPDMTeamManger or any case wher a team prefab or other is not specified. Consider it a backup even.

Spawn On Join

This determines WHEN the character prefab should be spawned. If this is true, the character prefab will be spawned upon the scene loading. This may not be desired if using a spawn panel. Examples are provided for use of this option, true or false.

Mode

This determines PLACEMENT of where the character should be initially spawned. Generally it is by spawnpoints for any game desgin, but the options are available to spawn at a fixed location with an offset applied per player. If a player is “Inactive” eg a non user disconnect or leave, then the player can rejoin, and be placed at the location where they are “lagged” out.

Spawn Location

Only applies when not using spawnpoints. A reference location to begin spawning characters.

Spawn Offset

Only applies when not using spawnpoints. How far the character should be spawned from the previously spawned player ID.

Spawn Point Grouping

This is a default setting, that will only be reverted to when there is no other spawn group management happening ie. when a MPDMTeamManager exists spawn grouping is determined by the MPTeamManger only when the relative input parameter is -1. Any time this is forced, the force group is used. This is how Objective/MiniMap spawning works, hence the local logic in each of them components to update and refresh required components at runtime.

Inactive Timeout

The duration a player can be considered “Inactive” when a non user disconnect has occured, keeping the room with a slot open for the disconnected player. This allows the disconnected player to rejoin the same room and game they were playing if they are reconnected in time.

Add Prefabs

With modurality in mind, the Add Prefabs section helps to define which prefabs to add to a local or remote prefab that is spawned.

LOCAL

Any prefabs that should be attached to the LOCAL character prefab should be defined here. NOTE: If you wish to utilise minimap, you can add the relevant prefab here, it has specific intialization for characters.

REMOTE

Any prefabs that should be attached to the REMOTE character prefab should be defined here. NOTE: If you wish to utilise minimap or name tag, you can add the relevant prefab/s here, They have specific intialization for characters.

Add Components

With modurality in mind, the Add Components section helps to define which components to add to a local or remote prefab that is spawned.

LOCAL

Any prefabs that should be attached to the LOCAL character prefab should be defined here. NOTE: If you wish to utilise minimap, you can add the relevant prefab here, it has specific intialization for characters.

REMOTE

Any prefabs that should be attached to the REMOTE character prefab should be defined here. NOTE: If you wish to utilise minimap or name tag, you can add the relevant prefab/s here, They have specific intialization for characters.

What are your feelings
Updated on August 14, 2023