diff options
author | pacien | 2018-01-10 19:37:16 +0100 |
---|---|---|
committer | pacien | 2018-01-10 19:37:16 +0100 |
commit | 0091983257c380097810d9c8989e4504917c2c5e (patch) | |
tree | 8571a1af6dcfa55a1fb86d14f1d323528dffd475 /src/docs | |
parent | 6ec0bbf3b3ca7e724430fd6037dfd6e2f1b9b983 (diff) | |
download | wallj-0091983257c380097810d9c8989e4504917c2c5e.tar.gz |
Implement block and block controller stubs
Signed-off-by: pacien <pacien.trangirard@pacien.net>
Diffstat (limited to 'src/docs')
-rw-r--r-- | src/docs/class.puml | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/src/docs/class.puml b/src/docs/class.puml index 21add0d..68aaf5e 100644 --- a/src/docs/class.puml +++ b/src/docs/class.puml | |||
@@ -126,26 +126,33 @@ package model { | |||
126 | GARBAGE | 126 | GARBAGE |
127 | ROBOT | 127 | ROBOT |
128 | BOMB | 128 | BOMB |
129 | |||
130 | boolean isBounding() | ||
131 | boolean mustBeReachable() | ||
132 | boolean isTraversable() | ||
133 | boolean isMovableByExplosion() | ||
129 | } | 134 | } |
130 | 135 | ||
131 | class BlockFactory { | 136 | class BlockFactory { |
132 | Block build(BlockType, Vec2) | 137 | Block build(BlockType, TileVec2) |
133 | } | 138 | } |
134 | 139 | ||
135 | abstract class Block { | 140 | abstract class Block { |
141 | BlockType | ||
136 | List<Controller> | 142 | List<Controller> |
143 | Vec2 | ||
137 | 144 | ||
138 | Block(Vec2) | 145 | Block(BlockType, List<Controller>, Vec2) |
139 | Vec2 getPosition() | 146 | void setPos(Vec2) |
140 | void setPosition(Vec2) | 147 | BlockType getBlockType() |
148 | Vec2 getPos() | ||
149 | TileVec2 getTile() | ||
141 | List<Event> update(Context) | 150 | List<Event> update(Context) |
142 | } | 151 | } |
143 | 152 | ||
144 | abstract class StaticBlock extends Block | 153 | class WallBlock extends Block |
145 | class WallBlock extends StaticBlock | 154 | class TrashBlock extends Block |
146 | class TrashBlock extends StaticBlock | 155 | class BombBlock extends Block |
147 | class BombBlock extends StaticBlock | ||
148 | |||
149 | class GarbageBlock extends Block | 156 | class GarbageBlock extends Block |
150 | class RobotBlock extends Block | 157 | class RobotBlock extends Block |
151 | 158 | ||
@@ -167,7 +174,6 @@ package controller { | |||
167 | abstract class BlockController implements Controller { | 174 | abstract class BlockController implements Controller { |
168 | Block | 175 | Block |
169 | Controller(Block) | 176 | Controller(Block) |
170 | Block getBlock() | ||
171 | } | 177 | } |
172 | 178 | ||
173 | class BlockControllerFactory { | 179 | class BlockControllerFactory { |