コード例 #1
0
 public static void ToNewGame(ContentManager content)
 {
     MapHandler.LoadMap("ObjectTest");
     Console.WriteLine("New Game started");
     Camera.camera.Position = new Vector2(0, 0);
     NewPlayer = new AttributesStruct();
     gameState = GameState.NewGame;
 }
コード例 #2
0
 public static void CharCreationStatsChange(AttributesStruct statsToADD)
 {
     NewPlayer.Age          = NewPlayer.Age + statsToADD.Age;
     NewPlayer.Charisma     = NewPlayer.Charisma + statsToADD.Charisma;
     NewPlayer.Constitution = NewPlayer.Constitution + statsToADD.Constitution;
     NewPlayer.Dexterity    = NewPlayer.Dexterity + statsToADD.Dexterity;
     NewPlayer.Intelligence = NewPlayer.Intelligence + statsToADD.Intelligence;
     NewPlayer.Strength     = NewPlayer.Strength + statsToADD.Strength;
 }
コード例 #3
0
ファイル: Character.cs プロジェクト: Iwan204/RPG-Game
 public override void Initialize(ContentManager content, Vector2 position)
 {
     Name         = "Default";
     IsCollidable = true;
     IsSelected   = false;
     sprite       = content.Load <Texture2D>("default");
     spriteBox    = new Rectangle((int)Position.X - 32, (int)Position.Y - 64, 32, 32);
     boundingBox  = new Rectangle((int)Position.X - 32, (int)Position.Y - 64, 64, 32);
     Elevation    = 0;
     Attributes   = new AttributesStruct();
     Stats        = new stats();
 }