C# 클래스 BattleShip.Ship

파일 보기 프로젝트 열기: LucienCamuglia/Battleships 1 사용 예제들

공개 메소드들

메소드 설명
GetCaseShip ( ) : BattleShip.casePlatform[]
IsInThePlatform ( int mouseX, int mouseY, GameBoard platform ) : void

check if the boats are in the ally platform and fit him to case

Ship ( int boat, int size ) : System
Ship ( int boat, int size, Point Location ) : System
drawShip ( Graphics g ) : void

draw a boat

isBetweenCase ( int mouseX, int mouseY ) : bool

Check the postion of the boat and the cursor of the mouse

rotateBoat ( ) : void

rotate the boat (inverse the height and the width of the boat)

메소드 상세

GetCaseShip() 공개 메소드

public GetCaseShip ( ) : BattleShip.casePlatform[]
리턴 BattleShip.casePlatform[]

IsInThePlatform() 공개 메소드

check if the boats are in the ally platform and fit him to case
public IsInThePlatform ( int mouseX, int mouseY, GameBoard platform ) : void
mouseX int position x of the mouse cursor
mouseY int position y of the mouse cursor
platform GameBoard
리턴 void

Ship() 공개 메소드

public Ship ( int boat, int size ) : System
boat int
size int
리턴 System

Ship() 공개 메소드

public Ship ( int boat, int size, Point Location ) : System
boat int
size int
Location Point
리턴 System

drawShip() 공개 메소드

draw a boat
public drawShip ( Graphics g ) : void
g System.Drawing.Graphics
리턴 void

isBetweenCase() 공개 메소드

Check the postion of the boat and the cursor of the mouse
public isBetweenCase ( int mouseX, int mouseY ) : bool
mouseX int position x of the mouse cursor
mouseY int position y of the mouse cursor
리턴 bool

rotateBoat() 공개 메소드

rotate the boat (inverse the height and the width of the boat)
public rotateBoat ( ) : void
리턴 void