Skip to content

Added worldmap road forking #1599

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 8, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions data/AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Most images were created either by grumbel or gwater. Check the log for details.
* images/background/ghostforest_grave.png - jkjkke - https://opengameart.org/content/background-6, edited, licensed under CC-BY 3.0
* images/objects/explosion/explosion*.png - Bleed - http://remusprites.carbonmade.com/ licensed under CC-BY 3.0, see https://opengameart.org/content/simple-explosion-bleeds-game-art
* images/engine/editor/sparkle-file.png - Semphris, licensed CC-BY 4.0 - CONTAINS WORK BY FortAwesome/FontAwesome (the file logo), licensed under CC-BY 4.0
* images/worldmap/shared/rocky_paths[-editor].png - Semphris, released under CC0

== Levels ==

Expand Down
24 changes: 23 additions & 1 deletion data/images/ice_world.strf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
(source "autotiles_ice_world.satc")
)

;; ice tiles- next id: 407
;; ice tiles- next id: 423
(tilegroup
(name (_ "Forest"))
(tiles
Expand Down Expand Up @@ -352,6 +352,11 @@
395 396 397 403
398 399 400 404
0 0 0 405

407 408 409 410
411 412 413 414
415 416 417 418
419 420 421 422
)
)
(tiles
Expand Down Expand Up @@ -435,6 +440,23 @@
12 12
)
)
(tiles
(width 4)(height 4)
(images "worldmap/shared/rocky_paths.png")
(editor-images "worldmap/shared/rocky_paths-editor.png")
(ids
407 408 409 410
411 412 413 414
415 416 417 418
419 420 421 422
)
(datas
6 30 10 18
23 31 27 3
5 29 9 17
20 12 24 0
)
)

(tilegroup
(name (_ "Water"))
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added data/images/worldmap/shared/rocky_paths.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions data/levels/world1/fork_in_the_road.stl
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,22 @@
(x 9440)
(y -128)
)
(scripttrigger
(script "state.fitr_up = true;")
(button #f)
(width 32)
(height 448)
(x 15104)
(y 0)
)
(scripttrigger
(script "state.fitr_down = true;")
(button #f)
(width 32)
(height 448)
(x 15104)
(y 544)
)
(sequencetrigger
(sequence "stoptux")
(width 64)
Expand Down Expand Up @@ -1534,6 +1550,7 @@ backclouds2.start_moving();")
(speed-x 0)
(speed-y -500)
(acceleration 100)
(affects-player #t)
(width 224)
(height 220)
(x 32)
Expand Down
8 changes: 8 additions & 0 deletions data/levels/world1/icy_valley.stl
Original file line number Diff line number Diff line change
Expand Up @@ -701,6 +701,14 @@
(x 96)
(y 0)
)
(scripttrigger
(script "state.iv_secret = true;")
(button #f)
(width 32)
(height 512)
(x 3488)
(y 0)
)
(sequencetrigger
(sequence "stoptux")
(width 64)
Expand Down
18 changes: 0 additions & 18 deletions data/levels/world1/underground.nut

This file was deleted.

61 changes: 61 additions & 0 deletions data/levels/world1/worldmap.nut
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@

fade_time <- 0.35;

// ============================================================================
// UNDERGROUND
// ============================================================================

if(! ("underground" in state)){
state.underground <- false;
print("[DEBUG] Underground state initialized\n");
}

function go_underground(under){
Underground_cover.fade(under ? 0 : 1, fade_time);
Land_foreground_1.fade(under ? 0 : 1, fade_time);
Land_foreground_2.fade(under ? 0 : 1, fade_time);
Land_foreground_3.fade(under ? 0 : 1, fade_time);
Land_foreground_4.fade(under ? 0 : 1, fade_time);
Underground_mask.fade(under ? 1 : 0, fade_time);
Underground_darkness.fade(under ? 1 : 0, fade_time);
state.underground <- under;
}

go_underground(state.underground);



// ============================================================================
// ROAD FORKS
// ============================================================================

if(! ("fitr_down" in state)){
state.fitr_down <- false;
print("[DEBUG] 'Fork in the Road' road fork (down) initialized\n");
}

if(! ("fitr_up" in state)){
state.fitr_up <- false;
print("[DEBUG] 'Fork in the Road' road fork (up) initialized\n");
}

fitr_down.set_solid(state.fitr_down);
fitr_up.set_solid(state.fitr_up);



// ============================================================================
// SECRET AREAS
// ============================================================================

if(! ("iv_secret" in state)){
state.iv_secret <- false;
print("[DEBUG] 'Icy Valley' secret road initialized\n");
}

function toggle_secret_road(tilemap, enabled){
tilemap.fade(enabled ? 1 : 0, fade_time);
tilemap.set_solid(enabled);
}

toggle_secret_road(iv_secret, state.iv_secret);
Loading