mirror of
https://github.com/JHDev2006/Super-Mario-Bros.-Remastered-Public.git
synced 2025-10-22 07:28:14 +00:00
re-implemented the respawning blocks + items fix, and got rid of a few annoying prints + removed the warning from the resource pack menu in the settings, as its no longer needed
This commit is contained in:
@@ -1,36 +1,156 @@
|
|||||||
{
|
{
|
||||||
"animations": {
|
"animations": {
|
||||||
"default": {
|
"default": {
|
||||||
"frames":
|
"frames": [
|
||||||
[
|
[
|
||||||
[0, 0, 16, 16],
|
0.0,
|
||||||
[0, 0, 16, 16],
|
0.0,
|
||||||
[0, 0, 16, 16],
|
16.0,
|
||||||
[0, 0, 16, 16],
|
16.0
|
||||||
[0, 0, 16, 16],
|
|
||||||
[0, 0, 16, 16],
|
|
||||||
[0, 0, 16, 16],
|
|
||||||
[0, 0, 16, 16],
|
|
||||||
[0, 0, 16, 16],
|
|
||||||
[0, 0, 16, 16],
|
|
||||||
[16, 0, 16, 16],
|
|
||||||
[32, 0, 16, 16],
|
|
||||||
[16, 0, 16, 16],
|
|
||||||
],
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
0.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
16.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
32.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
],
|
||||||
|
[
|
||||||
|
16.0,
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
],
|
||||||
"speed": 10.0,
|
"speed": 10.0,
|
||||||
"loop": true
|
"loop": true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"variations": {
|
||||||
"variations":
|
"default": {
|
||||||
{
|
"source": "QuestionBlock.png",
|
||||||
"default": {"source": "QuestionBlock.png", "rect": [0, 0, 64, 16]},
|
"rect": [
|
||||||
"Underground": {"source": "QuestionBlock.png", "rect": [0, 16, 64, 16]},
|
0.0,
|
||||||
"GhostHouse": {"link": "Underground"},
|
0.0,
|
||||||
"Castle": {"source": "QuestionBlock.png", "rect": [0, 32, 64, 16]},
|
64.0,
|
||||||
"Snow": {"source": "QuestionBlock.png", "rect": [0, 48, 64, 16]},
|
16.0
|
||||||
"Space": {"source": "QuestionBlock.png", "rect": [0, 64, 64, 16]},
|
]
|
||||||
"Volcano": {"source": "QuestionBlock.png", "rect": [0, 80, 64, 16]},
|
},
|
||||||
"Bonus": {"source": "QuestionBlock.png", "rect": [0, 96, 64, 16]}
|
"Underground": {
|
||||||
|
"source": "QuestionBlock.png",
|
||||||
|
"rect": [
|
||||||
|
0.0,
|
||||||
|
16.0,
|
||||||
|
64.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"GhostHouse": {
|
||||||
|
"link": "Underground"
|
||||||
|
},
|
||||||
|
"Castle": {
|
||||||
|
"source": "QuestionBlock.png",
|
||||||
|
"rect": [
|
||||||
|
0.0,
|
||||||
|
32.0,
|
||||||
|
64.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"Snow": {
|
||||||
|
"source": "QuestionBlock.png",
|
||||||
|
"rect": [
|
||||||
|
0.0,
|
||||||
|
48.0,
|
||||||
|
64.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"Space": {
|
||||||
|
"source": "QuestionBlock.png",
|
||||||
|
"rect": [
|
||||||
|
0.0,
|
||||||
|
64.0,
|
||||||
|
64.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"Volcano": {
|
||||||
|
"source": "QuestionBlock.png",
|
||||||
|
"rect": [
|
||||||
|
0.0,
|
||||||
|
80.0,
|
||||||
|
64.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"Bonus": {
|
||||||
|
"source": "QuestionBlock.png",
|
||||||
|
"rect": [
|
||||||
|
0.0,
|
||||||
|
96.0,
|
||||||
|
64.0,
|
||||||
|
16.0
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@@ -550,13 +550,6 @@ script = ExtResource("4_avtty")
|
|||||||
category_name = "SETTINGS_RESOURCE_PACK"
|
category_name = "SETTINGS_RESOURCE_PACK"
|
||||||
options = [NodePath("SelectableOptionNode"), NodePath("SelectableOptionNode2"), NodePath("SelectableOptionNode3")]
|
options = [NodePath("SelectableOptionNode"), NodePath("SelectableOptionNode2"), NodePath("SelectableOptionNode3")]
|
||||||
|
|
||||||
[node name="Label" type="Label" parent="PanelContainer/MarginContainer/VBoxContainer/ResourcePacks"]
|
|
||||||
visible = false
|
|
||||||
modulate = Color(1, 1, 0, 1)
|
|
||||||
layout_mode = 2
|
|
||||||
text = "RESOURCE_PACK_WARNING"
|
|
||||||
autowrap_mode = 2
|
|
||||||
|
|
||||||
[node name="SelectableOptionNode" parent="PanelContainer/MarginContainer/VBoxContainer/ResourcePacks" groups=["Options"] instance=ExtResource("9_t6b48")]
|
[node name="SelectableOptionNode" parent="PanelContainer/MarginContainer/VBoxContainer/ResourcePacks" groups=["Options"] instance=ExtResource("9_t6b48")]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
title = "RESOURCE_OPEN_FOLDER"
|
title = "RESOURCE_OPEN_FOLDER"
|
||||||
|
@@ -86,6 +86,8 @@ func spawn_empty_block() -> void:
|
|||||||
if get_parent().get_parent() is TrackRider:
|
if get_parent().get_parent() is TrackRider:
|
||||||
get_parent().get_parent().attached_entity = block
|
get_parent().get_parent().attached_entity = block
|
||||||
block_emptied.emit()
|
block_emptied.emit()
|
||||||
|
if get_parent() is TileMapLayer:
|
||||||
|
get_parent().erase_cell(get_parent().local_to_map(position))
|
||||||
queue_free()
|
queue_free()
|
||||||
|
|
||||||
func destroy() -> void:
|
func destroy() -> void:
|
||||||
@@ -94,5 +96,7 @@ func destroy() -> void:
|
|||||||
AudioManager.play_sfx("block_break", global_position)
|
AudioManager.play_sfx("block_break", global_position)
|
||||||
var particles = destruction_particle_scene.instantiate()
|
var particles = destruction_particle_scene.instantiate()
|
||||||
particles.global_position = global_position
|
particles.global_position = global_position
|
||||||
|
if get_parent() is TileMapLayer:
|
||||||
|
get_parent().erase_cell(get_parent().local_to_map(position))
|
||||||
add_sibling(particles)
|
add_sibling(particles)
|
||||||
queue_free()
|
queue_free()
|
||||||
|
@@ -57,7 +57,6 @@ func update_resource() -> void:
|
|||||||
cache.clear()
|
cache.clear()
|
||||||
property_cache.clear()
|
property_cache.clear()
|
||||||
if node_to_affect != null:
|
if node_to_affect != null:
|
||||||
print(resource_json.data)
|
|
||||||
var resource = get_resource(resource_json)
|
var resource = get_resource(resource_json)
|
||||||
node_to_affect.set(property_name, resource)
|
node_to_affect.set(property_name, resource)
|
||||||
if node_to_affect is AnimatedSprite2D:
|
if node_to_affect is AnimatedSprite2D:
|
||||||
@@ -210,7 +209,6 @@ func get_variation_json(json := {}) -> Dictionary:
|
|||||||
|
|
||||||
var campaign = Global.current_campaign
|
var campaign = Global.current_campaign
|
||||||
if force_properties.has("Campaign"):
|
if force_properties.has("Campaign"):
|
||||||
is_random = true
|
|
||||||
campaign = force_properties.Campaign
|
campaign = force_properties.Campaign
|
||||||
if json.has(campaign) == false:
|
if json.has(campaign) == false:
|
||||||
campaign = "SMB1"
|
campaign = "SMB1"
|
||||||
@@ -226,9 +224,7 @@ func get_variation_json(json := {}) -> Dictionary:
|
|||||||
|
|
||||||
var world = "World" + str(Global.world_num)
|
var world = "World" + str(Global.world_num)
|
||||||
if force_properties.has("World"):
|
if force_properties.has("World"):
|
||||||
is_random = true
|
|
||||||
world = "World" + str(force_properties.World)
|
world = "World" + str(force_properties.World)
|
||||||
print(world)
|
|
||||||
if json.has(world) == false:
|
if json.has(world) == false:
|
||||||
world = "World1"
|
world = "World1"
|
||||||
if json.has(world):
|
if json.has(world):
|
||||||
@@ -332,8 +328,6 @@ func load_image_from_path(path := "") -> Texture2D:
|
|||||||
return null
|
return null
|
||||||
return load(path)
|
return load(path)
|
||||||
var image = Image.new()
|
var image = Image.new()
|
||||||
if path == "":
|
|
||||||
print([path, owner.name])
|
|
||||||
image.load(path)
|
image.load(path)
|
||||||
return ImageTexture.create_from_image(image)
|
return ImageTexture.create_from_image(image)
|
||||||
|
|
||||||
|
@@ -16,7 +16,6 @@ func _ready() -> void:
|
|||||||
texture_changed.connect(update)
|
texture_changed.connect(update)
|
||||||
|
|
||||||
func update() -> void:
|
func update() -> void:
|
||||||
print(name)
|
|
||||||
var source = tile_map.tile_set.get_source(atlas_id)
|
var source = tile_map.tile_set.get_source(atlas_id)
|
||||||
if source != null:
|
if source != null:
|
||||||
source.texture = texture
|
source.texture = texture
|
||||||
|
@@ -24,12 +24,16 @@ func collect() -> void:
|
|||||||
$Sprite.queue_free()
|
$Sprite.queue_free()
|
||||||
else:
|
else:
|
||||||
queue_free()
|
queue_free()
|
||||||
|
if get_parent() is TileMapLayer:
|
||||||
|
get_parent().erase_cell(get_parent().local_to_map(position))
|
||||||
|
|
||||||
func summon_block_coin() -> void:
|
func summon_block_coin() -> void:
|
||||||
var node = spinning_coin_scene.instantiate()
|
var node = spinning_coin_scene.instantiate()
|
||||||
node.global_position = global_position
|
node.global_position = global_position
|
||||||
add_sibling(node)
|
add_sibling(node)
|
||||||
queue_free()
|
queue_free()
|
||||||
|
if get_parent() is TileMapLayer:
|
||||||
|
get_parent().erase_cell(get_parent().local_to_map(position))
|
||||||
|
|
||||||
func summon_particle() -> void:
|
func summon_particle() -> void:
|
||||||
var node = COIN_SPARKLE.instantiate()
|
var node = COIN_SPARKLE.instantiate()
|
||||||
|
Reference in New Issue
Block a user