public bool LandOnHorizontalPlatform(HorizontalPlatform platform) { LandOnPlatform(1, platform); Moving = true; if (platform.MoveRight) { DrawPos.X += 1; } else { DrawPos.X -= 1; } return(true); }
public static void ClassInit(TestContext context) { //Textures used don't matter, as none of them are initialized Player = new Player(Vector2.Zero); PrivatePlayer = new PrivateObject(Player); Enemy = new BaseEnemy(Vector2.Zero); PrivateEnemy = new PrivateObject(Enemy); Platform = new Platform(Vector2.Zero); PrivatePlatform = new PrivateObject(Platform); SpikePlatform = new SpikePlatform(Vector2.Zero); PrivateSpikePlatform = new PrivateObject(SpikePlatform); HorizontalPlatform = new HorizontalPlatform(Vector2.Zero); PrivateHorizontal = new PrivateObject(HorizontalPlatform); VerticalPlatform = new VerticalPlatform(Vector2.Zero); PrivateVertical = new PrivateObject(VerticalPlatform); IcePlatform = new IcePlatform(Vector2.Zero); PrivateIcePlatform = new PrivateObject(IcePlatform); CloudPlatform = new CloudPlatform(Vector2.Zero); PrivateCloudPlatform = new PrivateObject(CloudPlatform); }