Get Players 1 and 2

#Kismet

Gets player 1 and 2 and applies them to an object variable.


Have you ever wanted co-op compatibility to not be a pain? Well here we are!

LK_SeqAct_GetPlayers.uc

[RAW] [Download]

class LK_SeqAct_GetPlayers extends SequenceAction;
 
var Hat_Player PlayerOne, PlayerTwo;
 
event Activated() 
{
    PlayerOne = Hat_Player(class'Hat_PlayerController'.static.GetPlayer1().Pawn);
    PlayerTwo = Hat_Player(class'Hat_PlayerController'.static.GetPlayer2().Pawn);
}
 
defaultproperties
{
    ObjName="Get Players"
    ObjCategory="Lunar"
 
    VariableLinks.Empty
    VariableLinks(0)=(ExpectedType=class'SeqVar_Object',LinkDesc="Output  Player1",bWriteable=true,PropertyName=PlayerOne)
    VariableLinks(1)=(ExpectedType=class'SeqVar_Object',LinkDesc="Output  Player2",bWriteable=true,PropertyName=PlayerTwo)
}