Documentation ¶
Index ¶
- Constants
- func NewLevel(world w.World, newDepth int, width gc.Row, height gc.Col) loader.Level
- func SpawnFieldWall(world w.World, x gc.Row, y gc.Col) ecs.Entity
- func SpawnFieldWarpNext(world w.World, x gc.Row, y gc.Col) ecs.Entity
- func SpawnFloor(world w.World, x gc.Row, y gc.Col) ecs.Entity
- func SpawnPlayer(world w.World, x int, y int)
- func UpdateGameLayout(world w.World) (int, int)
- type Game
- type StateEvent
Constants ¶
View Source
const ( // MoveUpAction is the action for moving up MoveUpAction = "MoveUp" // MoveDownAction is the action for moving down MoveDownAction = "MoveDown" // MoveLeftAction is the action for moving left MoveLeftAction = "MoveLeft" // MoveRightAction is the action for moving right MoveRightAction = "MoveRight" // PreviousLevelAction is the action for switching to the previous level PreviousLevelAction = "PreviousLevel" // NextLevelAction is the action for switching to the next level NextLevelAction = "NextLevel" // RestartAction is the action for restarting the level RestartAction = "Restart" // GoToLevelAction is the action for switching to a specific level GoToLevelAction = "GoToLevel" )
View Source
const ( StateEventNone = StateEvent("NONE") StateEventWarpNext = StateEvent("WARP_NEXT") StateEventWarpEscape = StateEvent("WARP_ESCAPE") )
Variables ¶
This section is empty.
Functions ¶
func SpawnFieldWall ¶ added in v1.41.0
フィールド上に表示される壁を生成する
func SpawnFieldWarpNext ¶ added in v1.41.0
フィールド上に表示される階段を生成する
func SpawnFloor ¶ added in v1.41.0
フィールド上に表示される床を生成する
func SpawnPlayer ¶ added in v1.41.0
フィールド上に表示されるプレイヤーを生成する
Types ¶
Click to show internal directories.
Click to hide internal directories.