public Cannon(ContentManager Content) { this.cannonBarrel = Content.Load ( spr_cannon_barrel ); this.colorRed = Content.Load ( spr_cannon_red ); this.colorGreen = Content.Load ( spr_cannon_green ); this.colorBlue = Content.Load ( spr_cannon_blue ); this.currentColor = colorBlue; color = Color.Blue; barrelOrigin = new Vector2(cannonBarrel.Height, cannonBarrel.Height) / 2; colorOrigin = new Vector2(currentColor.Width, currentColor.Height) / 2; position = new Vector2(72, 405); } Parameter(s) van de constructormethode Member- variabelen krijgen een waarde.
{}