mirror of
https://github.com/JHDev2006/Super-Mario-Bros.-Remastered-Public.git
synced 2025-10-22 15:38:14 +00:00
fixed fonts not being loaded on export
This commit is contained in:
@@ -163,8 +163,11 @@ func get_resource(json_file: JSON) -> Resource:
|
||||
ResourceMode.RAW:
|
||||
pass
|
||||
ResourceMode.FONT:
|
||||
resource = FontFile.new()
|
||||
resource.load_bitmap_font(source_resource_path)
|
||||
if source_resource_path.contains(Global.get_config_path()):
|
||||
resource = FontFile.new()
|
||||
resource.load_bitmap_font(source_resource_path)
|
||||
else:
|
||||
resource = load(source_resource_path)
|
||||
resource.set_meta("base_path", source_resource_path)
|
||||
if cache.has(json_file.resource_path) == false and use_cache and not is_random:
|
||||
cache[json_file.resource_path] = resource
|
||||
|
@@ -8,6 +8,8 @@ var active := false
|
||||
@export_enum("Right", "Bottom") var direction := 0
|
||||
@export var entity_scene: PackedScene = null
|
||||
|
||||
signal activated
|
||||
|
||||
func _physics_process(delta: float) -> void:
|
||||
if active:
|
||||
spawn_meter += delta
|
||||
@@ -20,6 +22,7 @@ func activate() -> void:
|
||||
active = true
|
||||
spawn_meter = 0
|
||||
spawn_entity()
|
||||
activated.emit()
|
||||
|
||||
func deactivate_all_generators() -> void:
|
||||
for i in get_tree().get_nodes_in_group("EntityGenerators"):
|
||||
@@ -41,4 +44,7 @@ func spawn_entity() -> void:
|
||||
else:
|
||||
node.global_position.y = randf_range(0, -152)
|
||||
node.global_position.x = get_viewport().get_camera_2d().get_screen_center_position().x + ((get_viewport().get_visible_rect().size.x / 2) + 8)
|
||||
add_sibling(node)
|
||||
if get_parent() is EntityGenerator:
|
||||
get_parent().add_sibling(node)
|
||||
else:
|
||||
add_sibling(node)
|
||||
|
Reference in New Issue
Block a user