diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2018-08-13 12:29:03 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-08-13 12:29:03 +0200 |
commit | 7f49364fd073072c4db42428b1f67873a6e26d24 (patch) | |
tree | 4ae9badf2369a861cc2c9f79aaf33e038f7de0e5 /tests/manyloc/keineschweine | |
parent | dae5450947e93e2e5222ae2710874186bf27bf39 (diff) | |
download | Nim-7f49364fd073072c4db42428b1f67873a6e26d24.tar.gz |
make more tests green
Diffstat (limited to 'tests/manyloc/keineschweine')
-rw-r--r-- | tests/manyloc/keineschweine/lib/sg_assets.nim | 4 | ||||
-rw-r--r-- | tests/manyloc/keineschweine/lib/sg_gui.nim | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/manyloc/keineschweine/lib/sg_assets.nim b/tests/manyloc/keineschweine/lib/sg_assets.nim index 1e8a99c83..90f0a54e9 100644 --- a/tests/manyloc/keineschweine/lib/sg_assets.nim +++ b/tests/manyloc/keineschweine/lib/sg_assets.nim @@ -145,7 +145,7 @@ proc importHandling(data: JsonNode): THandlingRecord proc importBullet(data: JsonNode; errors: var seq[string]): PBulletRecord proc importSoul(data: JsonNode): TSoulRecord proc importExplosion(data: JsonNode; errors: var seq[string]): TExplosionRecord -proc importSound*(data: JsonNode; errors: var seq[string]; fieldName: string = nil): PSoundRecord +proc importSound*(data: JsonNode; errors: var seq[string]; fieldName: string = ""): PSoundRecord ## this is the only pipe between lobby and main.nim proc getActiveState*(): TGameState = @@ -514,7 +514,7 @@ proc importExplosion(data: JsonNode; errors: var seq[string]): TExplosionRecord let expl = data["explode"] result.anim = importAnim(expl, errors) result.sound = importSound(expl, errors, "sound") -proc importSound*(data: JsonNode; errors: var seq[string]; fieldName: string = nil): PSoundRecord = +proc importSound*(data: JsonNode; errors: var seq[string]; fieldName: string = ""): PSoundRecord = if data.kind == JObject: checkKey(data, fieldName) result = newSound(data[fieldName].str, errors) diff --git a/tests/manyloc/keineschweine/lib/sg_gui.nim b/tests/manyloc/keineschweine/lib/sg_gui.nim index 95cef1b24..074e0604c 100644 --- a/tests/manyloc/keineschweine/lib/sg_gui.nim +++ b/tests/manyloc/keineschweine/lib/sg_gui.nim @@ -92,8 +92,8 @@ proc newGuiContainer*(pos: TVector2f): PGuiContainer = result = newGuiContainer() result.setPosition pos proc free*(container: PGuiContainer) = - container.widgets = nil - container.buttons = nil + container.widgets = @[] + container.buttons = @[] proc add*(container: PGuiContainer; widget: PGuiObject) = container.widgets.add(widget) proc add*(container: PGuiContainer; button: PButton) = |