本文整理汇总了C#中PlayerController.setHealth方法的典型用法代码示例。如果您正苦于以下问题:C# PlayerController.setHealth方法的具体用法?C# PlayerController.setHealth怎么用?C# PlayerController.setHealth使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PlayerController
的用法示例。
在下文中一共展示了PlayerController.setHealth方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Start
// Use this for initialization
void Start()
{
//setDebugCharacters();
p1script = player1.GetComponent<PlayerController>();
p1AI = new PaddleAI(player1, ball);
PongCharacter p1char = new PongCharacter("Vida");
p2script = player2.GetComponent<PlayerController>();
p2AI = new PaddleAI(player2, ball);
//PongCharacter p2char = new PongCharacter("Sora");
PongCharacter p2char = new PongCharacter(PlayerPrefs.GetString("enemyName"));
//
p1script.setSkillPassive(p1char.getSkillPassive ());
p1script.setSkillA(p1char.getSkillA());
p1script.setSkillB(p1char.getSkillB());
p1script.setSkillC(p1char.getSkillC());
p1script.setHealth(p1char.getHealth());
p1script.setSpeed(p1char.getSpeed());
//
p2script.setSkillPassive(p2char.getSkillPassive());
p2script.setSkillA(p2char.getSkillA());
p2script.setSkillB(p2char.getSkillB());
p2script.setSkillC(p2char.getSkillC());
p2script.setHealth(p2char.getHealth());
p2script.setSpeed(p2char.getSpeed());
}