public SwitchModel(Game game, Pointf position) : base(game, position, new Size(10, 10), new Velocity()) { mBlocksOnCollision = false; mState = Status.OFF; }
public Hud(Pointf position, Game game, int level) : base(game) { HUD_WIDTH = Game.Window.ClientBounds.Width; mTextBox = game.Content.Load<Texture2D>("textbox"); mPosition = position; mCurrentTime = 0; playerDeathIndex = -1; // Set up variables to display text for level one mCurrentText = new List<String>(); mLevelText = new List<List<String>>(); // Text to display for level 1 switch (level) { case 1: mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Level1PlusSpeech1, TEXT_LINE_LIMIT)); mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Level1MinusSpeech1, TEXT_LINE_LIMIT)); mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Level1Info, TEXT_LINE_LIMIT)); break; case 2: mLevelText.Add(SpeechText.getTextArray(SpeechTextState.OneVsOneNarration, TEXT_LINE_LIMIT)); break; case 3: mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Boss1PlusSpeech1, TEXT_LINE_LIMIT)); mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Boss1BossSpeech1, TEXT_LINE_LIMIT)); mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Boss1MinusSpeech1, TEXT_LINE_LIMIT)); mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Boss1PlusSpeech2, TEXT_LINE_LIMIT)); mLevelText.Add(SpeechText.getTextArray(SpeechTextState.Boss1BossSpeech2, TEXT_LINE_LIMIT)); break; } }
public Character(Game game, Pointf position, Size size, Velocity velocity, PlayerIndex index ) : base(game, position, size, velocity) { EnableFreeFall(); currentPlayer = index; if (currentPlayer == PlayerIndex.One) { mPlayerIndex = 0; } else if (currentPlayer == PlayerIndex.Two) { mPlayerIndex = 1; } else { mPlayerIndex = 2; } mSongJump = game.Content.Load<SoundEffect>("jump4"); }
public Model(Game game, Pointf position, Size size, Velocity velocity) : this(game, position, size, velocity, 0) { }
public Displayable(Pointf position, Size size, Velocity velocity) { Position = new Pointf(position); Size = new Size(size); mVelocity = new Velocity(velocity); }
public Wall(Game game, Pointf position, Size size, Colors color) : base(game, position, size, new Velocity(), (int)color) { mBlocksOnCollision = true; isHorizontal = true; if (size.Height > size.Width) { isHorizontal = false; } }
public ExampleModel(Game game, Pointf position, Size size, Velocity velocity) : base(game, position, size, velocity, 0) { // how you would move mPosition.X = 40; Velocity.Speed = new Vector2(1,1); Velocity.Direction = new Vector2(2, 0); }
public Model(Game game, Pointf position, Size size, Velocity velocity, int parameterized) : base(game, new Displayable(position, size, velocity), parameterized) { mDestroy = false; mId = idCntr++; mIsFreeFall = false; mFrames = new List<Frame>(); GenerateFrames(); mPosition.X += size.Width / 2; mPosition.Y += size.Height / 2; }
public static Wall BuildWall(Pointf wallPosition, Size wallSize, Wall.Colors wallColor, ref MapModel map) { Wall wall = new Wall(map.Game, new Pointf(wallPosition.X, wallPosition.Y), new Size(wallSize.Width, wallSize.Height), wallColor); map.AddComponent(wall); return wall; }
public static SwitchModel BuildSwitch(Pointf switchPosition) { var temp = GetMap(); return BuildSwitch(switchPosition, ref temp); }
public static SwitchModel BuildSwitch(Pointf switchPosition, ref MapModel map) { SwitchModel toAdd = new SwitchModel(map.Game, switchPosition); map.AddComponent(toAdd); return toAdd; }
public static Collectable BuildCollectable(Pointf position, ref MapModel map, int points) { Collectable c = new Collectable(map.Game, position, points); map.AddComponent(c); return c; }
public static Resistor BuildResistor(Pointf position, Resistor.Type index) { var temp = GetMap(); return BuildResistor(position, index, ref temp); }
public static Resistor BuildResistor(Pointf position, Resistor.Type index, ref MapModel map) { Resistor res = new Resistor(map.Game, position, index); map.AddComponent(res); return res; }
public MoveableBox(Game game, Pointf position, Size size) : base(game, position, size, new Velocity()) { mBlockedWallId = -1; EnableFreeFall(); }
public WaterModel(Game game, Pointf position) : base(game, position, new Size(10, 2), new Velocity()) { }
public static ElevatorModel BuildElevator(Pointf elevatorPosition, ref MapModel map) { return BuildElevator(elevatorPosition, GetDefaultElevatorColumnSpan() * DEFAULT_PLATFORM_WIDTH, GetDefaultElevatorLevelSplan() * DEFAULT_PLATFORM_HEIGHT, ref map); }
public static ElevatorModel BuildElevator(Pointf elevatorPosition, float elevatorWidth, float maxMovementHeight, ref MapModel map) { ElevatorModel elev = new ElevatorModel(map.Game, elevatorWidth, maxMovementHeight, elevatorPosition); map.AddComponent(elev); return elev; }
public static Wall BuildWall(Pointf wallPosition, Size wallSize, Wall.Colors wallColor) { var temp = GetMap(); return BuildWall(wallPosition, wallSize, wallColor, ref temp); }
public Resistor(Game game, Pointf position, Type type) : base(game, position, new Size(45, 20), new Velocity(), (int)type) { DisableFreeFall(); mBlocksOnCollision = false; }
public Frame(Pointf position, Size size) { mArea = new Rectangle((int)position.X, (int)position.Y, (int)size.Width, (int)size.Height); }
public ExitDoorModel(Game game,Pointf position, PlayerIndex pIndex) : base(game,new Pointf(position.X, position.Y - 64), new Size(96,64),new Velocity(),(int)pIndex) { mBlocksOnCollision = false; }
public static Collectable BuildCollectable(Pointf position, int points) { var temp = GetMap(); return BuildCollectable(position, ref temp, points); }
public static ExitDoorModel BuildExitDoor(Pointf doorPosition, PlayerIndex playerIndex, ref MapModel map) { ExitDoorModel exit = new ExitDoorModel(map.Game, doorPosition, playerIndex); map.AddComponent(exit); return exit; }
public static ElevatorModel BuildElevator(Pointf elevatorPosition, float elevatorWidth, float maxMovementHeight) { var temp = GetMap(); return BuildElevator(elevatorPosition, elevatorWidth, maxMovementHeight, ref temp); }
public static ExitDoorModel BuildExitDoor(Pointf doorPosition, PlayerIndex playerIndex) { var temp = GetMap(); return BuildExitDoor(doorPosition, playerIndex, ref temp); }
public static ElevatorModel BuildElevator(Pointf elevatorPosition) { var temp = GetMap(); return BuildElevator(elevatorPosition, ref temp); }
public static MoveableBox BuildMoveableBox(Pointf boxPosition, Size boxSize, ref MapModel map) { MoveableBox box = new MoveableBox(map.Game, boxPosition, boxSize); map.AddComponent(box); return box; }
public Collectable(Game game, Pointf position, int points) : base(game, position, new Size(30,30), new Velocity()) { mPoints = points; DisableFreeFall(); }
public static MoveableBox BuildMoveableBox(Pointf boxPosition, Size boxSize) { var temp = GetMap(); return BuildMoveableBox(boxPosition, boxSize, ref temp); }