[TIP] Change Player Models based on Team for Multiplayer Team Deathmatch

In my game i implemented Team Deathmatch a few days ago but was struggling to update player mesh based on Team. But today i finally managed to do it and decided to share incase if anyone else is facing the same problem.

In your custom Team Deathmatch Game class add the below code:

function class<Pawn> GetDefaultPlayerClass(Controller C)
    if (C.PlayerReplicationInfo.Team.GetTeamNum() == 0)
        return class'Team0PawnClass';
    return class'Team1PawnClass';

Thats it! We just override the GetDefaultPlayerClass function to get the player model based on Team.

Hope you find this useful.


About Satheesh (ryanjon2040)

Genuine Unreal Engine user

Posted on August 8, 2013, in Tutorials and tagged , , , . Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: