Try to fix pre-release bug and fail
This commit is contained in:
parent
aa3fc3bb5f
commit
734858c926
|
@ -0,0 +1,123 @@
|
||||||
|
[preset.0]
|
||||||
|
|
||||||
|
name="HTML5"
|
||||||
|
platform="HTML5"
|
||||||
|
runnable=true
|
||||||
|
custom_features=""
|
||||||
|
export_filter="all_resources"
|
||||||
|
include_filter=""
|
||||||
|
exclude_filter=""
|
||||||
|
export_path="build/ld48-gravity_limbo.html"
|
||||||
|
patch_list=PoolStringArray( )
|
||||||
|
script_export_mode=1
|
||||||
|
script_encryption_key=""
|
||||||
|
|
||||||
|
[preset.0.options]
|
||||||
|
|
||||||
|
vram_texture_compression/for_desktop=true
|
||||||
|
vram_texture_compression/for_mobile=false
|
||||||
|
html/custom_html_shell=""
|
||||||
|
html/head_include=""
|
||||||
|
custom_template/release=""
|
||||||
|
custom_template/debug=""
|
||||||
|
|
||||||
|
[preset.1]
|
||||||
|
|
||||||
|
name="Linux/X11"
|
||||||
|
platform="Linux/X11"
|
||||||
|
runnable=true
|
||||||
|
custom_features=""
|
||||||
|
export_filter="all_resources"
|
||||||
|
include_filter=""
|
||||||
|
exclude_filter=""
|
||||||
|
export_path="build/ld48-gravity_limbo.x86_64"
|
||||||
|
patch_list=PoolStringArray( )
|
||||||
|
script_export_mode=1
|
||||||
|
script_encryption_key=""
|
||||||
|
|
||||||
|
[preset.1.options]
|
||||||
|
|
||||||
|
texture_format/bptc=false
|
||||||
|
texture_format/s3tc=true
|
||||||
|
texture_format/etc=false
|
||||||
|
texture_format/etc2=false
|
||||||
|
texture_format/no_bptc_fallbacks=true
|
||||||
|
binary_format/64_bits=true
|
||||||
|
binary_format/embed_pck=false
|
||||||
|
custom_template/release=""
|
||||||
|
custom_template/debug=""
|
||||||
|
|
||||||
|
[preset.2]
|
||||||
|
|
||||||
|
name="Windows Desktop"
|
||||||
|
platform="Windows Desktop"
|
||||||
|
runnable=true
|
||||||
|
custom_features=""
|
||||||
|
export_filter="all_resources"
|
||||||
|
include_filter=""
|
||||||
|
exclude_filter=""
|
||||||
|
export_path="build/ld48-gravity_limbo.exe"
|
||||||
|
patch_list=PoolStringArray( )
|
||||||
|
script_export_mode=1
|
||||||
|
script_encryption_key=""
|
||||||
|
|
||||||
|
[preset.2.options]
|
||||||
|
|
||||||
|
texture_format/bptc=false
|
||||||
|
texture_format/s3tc=true
|
||||||
|
texture_format/etc=false
|
||||||
|
texture_format/etc2=false
|
||||||
|
texture_format/no_bptc_fallbacks=true
|
||||||
|
binary_format/64_bits=true
|
||||||
|
binary_format/embed_pck=false
|
||||||
|
custom_template/release=""
|
||||||
|
custom_template/debug=""
|
||||||
|
codesign/enable=false
|
||||||
|
codesign/identity=""
|
||||||
|
codesign/password=""
|
||||||
|
codesign/timestamp=true
|
||||||
|
codesign/timestamp_server_url=""
|
||||||
|
codesign/digest_algorithm=1
|
||||||
|
codesign/description=""
|
||||||
|
codesign/custom_options=PoolStringArray( )
|
||||||
|
application/icon=""
|
||||||
|
application/file_version=""
|
||||||
|
application/product_version=""
|
||||||
|
application/company_name=""
|
||||||
|
application/product_name=""
|
||||||
|
application/file_description=""
|
||||||
|
application/copyright=""
|
||||||
|
application/trademarks=""
|
||||||
|
|
||||||
|
[preset.3]
|
||||||
|
|
||||||
|
name="Mac OSX"
|
||||||
|
platform="Mac OSX"
|
||||||
|
runnable=true
|
||||||
|
custom_features=""
|
||||||
|
export_filter="all_resources"
|
||||||
|
include_filter=""
|
||||||
|
exclude_filter=""
|
||||||
|
export_path="build/ld48-gravity_limbo.macosx.zip"
|
||||||
|
patch_list=PoolStringArray( )
|
||||||
|
script_export_mode=1
|
||||||
|
script_encryption_key=""
|
||||||
|
|
||||||
|
[preset.3.options]
|
||||||
|
|
||||||
|
custom_template/debug=""
|
||||||
|
custom_template/release=""
|
||||||
|
application/name=""
|
||||||
|
application/info="Made with Godot Engine"
|
||||||
|
application/icon=""
|
||||||
|
application/identifier=""
|
||||||
|
application/signature=""
|
||||||
|
application/short_version="1.0"
|
||||||
|
application/version="1.0"
|
||||||
|
application/copyright=""
|
||||||
|
display/high_res=false
|
||||||
|
privacy/camera_usage_description=""
|
||||||
|
privacy/microphone_usage_description=""
|
||||||
|
texture_format/s3tc=true
|
||||||
|
texture_format/etc=false
|
||||||
|
texture_format/etc2=false
|
|
@ -300,8 +300,27 @@ const EncounterData = {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"Comet" : {},
|
"Comet" : {
|
||||||
"Debris" : {},
|
"tooltip": "",
|
||||||
|
"situations": {
|
||||||
|
0: {
|
||||||
|
"title": "Extra-solar fly-by",
|
||||||
|
"picture": null,
|
||||||
|
"text": "A large comet blazes through the system, passing nearby. It leaves sparkling trails of ice and gases in it's wake",
|
||||||
|
"choices": {
|
||||||
|
0: {
|
||||||
|
"title": "Observer the comet",
|
||||||
|
"then": "You direct the majority of the sensors on your ship to observe the comet, and the crew crams in the observation deck to catch glimpses of the fly-by",
|
||||||
|
"results": {
|
||||||
|
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
"Debris" : {
|
||||||
|
},
|
||||||
#"Gases" : {},
|
#"Gases" : {},
|
||||||
"Mystery" : {},
|
"Mystery" : {},
|
||||||
"Alien" : {},
|
"Alien" : {},
|
||||||
|
@ -543,15 +562,21 @@ func generate_encounter_instance(data, level = null, index = null):
|
||||||
self.encounters[level][index]["instance"] = instance
|
self.encounters[level][index]["instance"] = instance
|
||||||
return instance
|
return instance
|
||||||
|
|
||||||
func goto_scene(scene, current = null):
|
func goto_scene(scene, current = null, free = true):
|
||||||
call_deferred("_deferred_goto_scene", scene, current)
|
call_deferred("_deferred_goto_scene", scene, current, free)
|
||||||
|
|
||||||
func _deferred_goto_scene(scene, current = null):
|
func _deferred_goto_scene(scene, current = null, free = true):
|
||||||
get_tree().get_root().print_tree_pretty()
|
get_tree().get_root().print_tree_pretty()
|
||||||
if current:
|
if current:
|
||||||
current.free()
|
if free:
|
||||||
|
current.free()
|
||||||
|
else:
|
||||||
|
current.set_visible(false)
|
||||||
elif self.current_scene:
|
elif self.current_scene:
|
||||||
self.current_scene.free()
|
if free:
|
||||||
|
self.current_scene.free()
|
||||||
|
else:
|
||||||
|
self.current_scene.set_visible(false)
|
||||||
var next = ResourceLoader.load(scene).instance()
|
var next = ResourceLoader.load(scene).instance()
|
||||||
get_tree().get_root().add_child(next)
|
get_tree().get_root().add_child(next)
|
||||||
get_tree().set_current_scene(next)
|
get_tree().set_current_scene(next)
|
||||||
|
@ -573,10 +598,12 @@ func start_encounters(picks):
|
||||||
x += 1
|
x += 1
|
||||||
if self.current_state < 5:
|
if self.current_state < 5:
|
||||||
self.current_state = 5
|
self.current_state = 5
|
||||||
|
self.goto_scene("res://src/ui/Encounters.tscn")
|
||||||
if self.current_state > 5:
|
if self.current_state > 5:
|
||||||
self.current_state = 8
|
self.current_state = 8
|
||||||
|
self.goto_scene("res://src/ui/Encounters.tscn", null, false)
|
||||||
|
|
||||||
|
|
||||||
self.goto_scene("res://src/ui/Encounters.tscn")
|
|
||||||
|
|
||||||
func choose_flightpath_out():
|
func choose_flightpath_out():
|
||||||
GameState.current_state = 7
|
GameState.current_state = 7
|
||||||
|
@ -584,7 +611,7 @@ func choose_flightpath_out():
|
||||||
self.ship_stats['starting_position'] = get_tree().get_root().get_node("Encounters/Map/Ship").get_global_position()
|
self.ship_stats['starting_position'] = get_tree().get_root().get_node("Encounters/Map/Ship").get_global_position()
|
||||||
self.encounters.erase(GameState.current_depth)
|
self.encounters.erase(GameState.current_depth)
|
||||||
GameState.current_depth -= 1
|
GameState.current_depth -= 1
|
||||||
self.goto_scene("res://src/ui/ChooseFlightIn.tscn")
|
self.goto_scene("res://src/ui/ChooseFlightIn.tscn", null, false)
|
||||||
|
|
||||||
func update_stats(d):
|
func update_stats(d):
|
||||||
for k in d.keys():
|
for k in d.keys():
|
||||||
|
|
|
@ -19,7 +19,8 @@ func _ready():
|
||||||
# Bind button callbacks
|
# Bind button callbacks
|
||||||
for n in buttonNames:
|
for n in buttonNames:
|
||||||
var button = self.find_node(n)
|
var button = self.find_node(n)
|
||||||
button.connect("toggled", self, "_on_option_button_pressed", [n])
|
if button:
|
||||||
|
button.connect("toggled", self, "_on_option_button_pressed", [n])
|
||||||
|
|
||||||
func initialize(l = null, nOptions = null):
|
func initialize(l = null, nOptions = null):
|
||||||
self.level = l
|
self.level = l
|
||||||
|
@ -68,19 +69,24 @@ func get_active_position():
|
||||||
var i = get_active_option_index()
|
var i = get_active_option_index()
|
||||||
if i == null:
|
if i == null:
|
||||||
return null
|
return null
|
||||||
return get_node("Option" + str(i)).get_global_position()
|
var n = "Option" + str(i)
|
||||||
|
if get_node(n):
|
||||||
|
return get_node(n).get_global_position()
|
||||||
|
else:
|
||||||
|
return null
|
||||||
|
|
||||||
func has_active():
|
func has_active():
|
||||||
var active = false
|
var active = false
|
||||||
for n in buttonNames:
|
for n in buttonNames:
|
||||||
active = active or (self.get_node(n).is_pressed() and self.get_node(n).is_visible())
|
if get_node(n):
|
||||||
|
active = active or (self.get_node(n).is_pressed() and self.get_node(n).is_visible())
|
||||||
return active
|
return active
|
||||||
|
|
||||||
func _on_option_button_pressed(state, buttonName):
|
func _on_option_button_pressed(state, buttonName):
|
||||||
for n in buttonNames:
|
for n in buttonNames:
|
||||||
if n != buttonName:
|
if n != buttonName:
|
||||||
if state:
|
if state and get_node(n):
|
||||||
self.find_node(n).set_pressed(false)
|
self.get_node(n).set_pressed(false)
|
||||||
emit_signal("encounter_choice_changed")
|
emit_signal("encounter_choice_changed")
|
||||||
#for n in buttonNames:
|
#for n in buttonNames:
|
||||||
# if self.find_node(n).is_pressed():
|
# if self.find_node(n).is_pressed():
|
||||||
|
|
|
@ -46,8 +46,10 @@ func _on_encounter_complete(instance):
|
||||||
self.next_encounter()
|
self.next_encounter()
|
||||||
|
|
||||||
func next_encounter():
|
func next_encounter():
|
||||||
|
print("Heading to next encounter")
|
||||||
print(GameState.current_depth)
|
print(GameState.current_depth)
|
||||||
print(GameState.current_state)
|
print(GameState.current_state)
|
||||||
|
print(GameState.encounters)
|
||||||
if GameState.current_state != 5 and GameState.current_state != 8:
|
if GameState.current_state != 5 and GameState.current_state != 8:
|
||||||
return
|
return
|
||||||
if (self.direction == 1 and GameState.current_depth < (len(GameState.encounters) - 1)) \
|
if (self.direction == 1 and GameState.current_depth < (len(GameState.encounters) - 1)) \
|
||||||
|
@ -58,9 +60,10 @@ func next_encounter():
|
||||||
"supplies": -GameState.get_supply_upkeep(),
|
"supplies": -GameState.get_supply_upkeep(),
|
||||||
})
|
})
|
||||||
if get_node("Map/Level" + str(GameState.current_depth)):
|
if get_node("Map/Level" + str(GameState.current_depth)):
|
||||||
GameState.update_stats({
|
if get_node("Map/Level" + str(GameState.current_depth)).get_active_position():
|
||||||
"target_position": get_node("Map/Level" + str(GameState.current_depth)).get_active_position(),
|
GameState.update_stats({
|
||||||
})
|
"target_position": get_node("Map/Level" + str(GameState.current_depth)).get_active_position(),
|
||||||
|
})
|
||||||
GameState.update_orbit({
|
GameState.update_orbit({
|
||||||
"altitude": -self.direction * (GameState.get_difficulty_data("starting_altitude") - GameState.get_difficulty_data("minimum_altitude")) / len(GameState.encounters)
|
"altitude": -self.direction * (GameState.get_difficulty_data("starting_altitude") - GameState.get_difficulty_data("minimum_altitude")) / len(GameState.encounters)
|
||||||
})
|
})
|
||||||
|
|
|
@ -56,6 +56,10 @@ func _ready():
|
||||||
#n.set_normal_texture(n.get_pressed_texture())
|
#n.set_normal_texture(n.get_pressed_texture())
|
||||||
if GameState.encounters[level][x]["visited"]:
|
if GameState.encounters[level][x]["visited"]:
|
||||||
n.set_visible(false)
|
n.set_visible(false)
|
||||||
|
# Don't free, because we have some bugs where we refer to the option again.
|
||||||
|
# This is a problem and leads to weird behaviour but I guess we'll have to live
|
||||||
|
# with it.
|
||||||
|
#n.free()
|
||||||
x += 1
|
x += 1
|
||||||
if GameState.current_state == 4: # picking course
|
if GameState.current_state == 4: # picking course
|
||||||
choice.activate_options()
|
choice.activate_options()
|
||||||
|
@ -64,9 +68,10 @@ func _ready():
|
||||||
choice.connect("encounter_choice_changed", self, "_on_encounter_choice_changed")
|
choice.connect("encounter_choice_changed", self, "_on_encounter_choice_changed")
|
||||||
self.draw_course()
|
self.draw_course()
|
||||||
|
|
||||||
func _process(delta):
|
func _process(_delta):
|
||||||
var s = get_node("Ship")
|
var s = get_node("Ship")
|
||||||
#print(GameState.ship_stats["target_position"])
|
if GameState.ship_stats["target_position"] == null:
|
||||||
|
GameState.ship_stats["target_position"] = Vector2(0, 0)
|
||||||
if s.get_global_position().distance_to(GameState.ship_stats["target_position"]) >= 5:
|
if s.get_global_position().distance_to(GameState.ship_stats["target_position"]) >= 5:
|
||||||
ship_moving = true
|
ship_moving = true
|
||||||
s.set_global_position(s.get_global_position().move_toward(GameState.ship_stats["target_position"], 5.0))
|
s.set_global_position(s.get_global_position().move_toward(GameState.ship_stats["target_position"], 5.0))
|
||||||
|
@ -92,7 +97,6 @@ func draw_course():
|
||||||
while x < (len(GameState.encounters) - 1):
|
while x < (len(GameState.encounters) - 1):
|
||||||
pairs.append([x, x+1])
|
pairs.append([x, x+1])
|
||||||
x += 1
|
x += 1
|
||||||
var paths = []
|
|
||||||
print(pairs)
|
print(pairs)
|
||||||
for p in pairs:
|
for p in pairs:
|
||||||
var first = get_node("Level" + str(p[0]))
|
var first = get_node("Level" + str(p[0]))
|
||||||
|
|
Loading…
Reference in New Issue