PICLET
Browse files
src/lib/components/Pages/Battle.svelte
CHANGED
@@ -156,6 +156,7 @@
|
|
156 |
|
157 |
const moveAction: MoveAction = {
|
158 |
type: 'move',
|
|
|
159 |
moveIndex: battleState.playerPiclet.moves.indexOf(battleMove)
|
160 |
};
|
161 |
|
@@ -418,7 +419,8 @@
|
|
418 |
const enemyMoveIndex = battleState.opponentPiclet.moves.indexOf(randomEnemyMove);
|
419 |
|
420 |
return {
|
421 |
-
type: 'move',
|
|
|
422 |
moveIndex: enemyMoveIndex
|
423 |
};
|
424 |
} else {
|
@@ -427,7 +429,8 @@
|
|
427 |
const enemyMoveIndex = battleState.opponentPiclet.moves.indexOf(randomEnemyMove);
|
428 |
|
429 |
return {
|
430 |
-
type: 'move',
|
|
|
431 |
moveIndex: enemyMoveIndex
|
432 |
};
|
433 |
}
|
|
|
156 |
|
157 |
const moveAction: MoveAction = {
|
158 |
type: 'move',
|
159 |
+
piclet: 'player',
|
160 |
moveIndex: battleState.playerPiclet.moves.indexOf(battleMove)
|
161 |
};
|
162 |
|
|
|
419 |
const enemyMoveIndex = battleState.opponentPiclet.moves.indexOf(randomEnemyMove);
|
420 |
|
421 |
return {
|
422 |
+
type: 'move',
|
423 |
+
piclet: 'opponent',
|
424 |
moveIndex: enemyMoveIndex
|
425 |
};
|
426 |
} else {
|
|
|
429 |
const enemyMoveIndex = battleState.opponentPiclet.moves.indexOf(randomEnemyMove);
|
430 |
|
431 |
return {
|
432 |
+
type: 'move',
|
433 |
+
piclet: 'opponent',
|
434 |
moveIndex: enemyMoveIndex
|
435 |
};
|
436 |
}
|