Skip to content

Commit

Permalink
fix(jsbattle-engine): clone timeLimit of UltimateBattleDescriptor pro…
Browse files Browse the repository at this point in the history
…perly #31
  • Loading branch information
jamro committed Aug 4, 2020
1 parent a842952 commit 02f7525
Show file tree
Hide file tree
Showing 15 changed files with 6 additions and 3 deletions.
Binary file modified packages/jsbattle-docs/docs/img/puml/ai.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/comp_microservices.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/comp_overview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/infra_simple.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/infrastructure.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/microservices.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/overview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/packages.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/renderer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/sim_seq.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified packages/jsbattle-docs/docs/img/puml/view.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ class UltimateBattleDescriptor {
let result = new UltimateBattleDescriptor();
result.setRngSeed(this.getRngSeed());
result.setTeamMode(this.getTeamMode());
result.setTimeLimit(this.getTimeLimit());
let aiList = this.getAiList();
let aiClone;
for(let ai of aiList) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ describe('UltimateBattleDescriptor', function() {
it('should copy the descriptor', function() {
let desc = new UltimateBattleDescriptor();
desc.setRngSeed(342);
desc.setTimeLimit(9984);
desc.setTeamMode(true);
desc.addAiDefinition(new AiDefinitionMock("tank1"));
desc.addAiDefinition(new AiDefinitionMock("tank2"));
Expand All @@ -56,6 +57,7 @@ describe('UltimateBattleDescriptor', function() {
assert.equal(2, clone.getAiList().length);
assert.equal(desc.getVersion(), clone.getVersion());
assert.equal(true, clone.getTeamMode());
assert.equal(9984, clone.getTimeLimit());

});

Expand Down

Large diffs are not rendered by default.

Large diffs are not rendered by default.

0 comments on commit 02f7525

Please sign in to comment.