Skip to content

Commit

Permalink
Disable angery mode, add mod author prob setting
Browse files Browse the repository at this point in the history
  • Loading branch information
TheHorscht committed Feb 26, 2020
1 parent fa0610c commit 66bd27f
Show file tree
Hide file tree
Showing 11 changed files with 39 additions and 16 deletions.
4 changes: 4 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v1.4.7:
- Added support for other mod authors to influence anvil spawn probability
- Removed the anvil damage check again because it triggered even though nothing was damaged...

v1.4.6:
- Anvil damage detection is working again (albeit slightly different) and statues are willing to get angry again
- Added smithing animation!
Expand Down
4 changes: 3 additions & 1 deletion files/biomes/coalmine.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for coalmine: " .. max_prob)
end

local probability = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_02, {
prob = get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene),
prob = probability,
material_file = "mods/anvil_of_destiny/files/loader_scenes/coalmine.png",
visual_file = "",
background_file = "",
Expand Down
4 changes: 3 additions & 1 deletion files/biomes/crypt.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for crypt: " .. max_prob)
end

local probability = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_03, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_03, {
prob = get_probability_value_for_inserting(g_pixel_scene_03, probability_to_replace_pixelscene),
prob = probability,
material_file = "mods/anvil_of_destiny/files/loader_scenes/crypt.png",
visual_file = "",
background_file = "",
Expand Down
7 changes: 5 additions & 2 deletions files/biomes/excavationsite.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,19 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for excavationsite: " .. max_prob)
end

local probability1 = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_04, probability_to_replace_pixelscene)
local probability2 = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_04_alt, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_04, {
prob = get_probability_value_for_inserting(g_pixel_scene_04, probability_to_replace_pixelscene),
prob = probability1,
material_file = "mods/anvil_of_destiny/files/loader_scenes/excavationsite.png",
visual_file = "",
background_file = "",
is_unique = 0
})

table.insert(g_pixel_scene_04_alt, {
prob = get_probability_value_for_inserting(g_pixel_scene_04_alt, probability_to_replace_pixelscene),
prob = probability2,
material_file = "mods/anvil_of_destiny/files/loader_scenes/excavationsite.png",
visual_file = "",
background_file = "",
Expand Down
4 changes: 3 additions & 1 deletion files/biomes/pyramid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for pyramid: " .. max_prob)
end

local probability = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_03, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_03, {
prob = get_probability_value_for_inserting(g_pixel_scene_03, probability_to_replace_pixelscene),
prob = probability,
material_file = "mods/anvil_of_destiny/files/loader_scenes/pyramid.png",
visual_file = "",
background_file = "",
Expand Down
7 changes: 5 additions & 2 deletions files/biomes/rainforest.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,19 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for rainforest: " .. max_prob)
end

local probability1 = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_01, probability_to_replace_pixelscene)
local probability2 = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_01, {
prob = get_probability_value_for_inserting(g_pixel_scene_01, probability_to_replace_pixelscene),
prob = probability1,
material_file = "mods/anvil_of_destiny/files/loader_scenes/rainforest_v.png",
visual_file = "",
background_file = "",
is_unique = 0
})

table.insert(g_pixel_scene_02, {
prob = get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene),
prob = probability2,
material_file = "mods/anvil_of_destiny/files/loader_scenes/rainforest_h.png",
visual_file = "",
background_file = "",
Expand Down
4 changes: 3 additions & 1 deletion files/biomes/snowcastle.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for snowcastle: " .. max_prob)
end

local probability = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_02, {
prob = get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene),
prob = probability,
material_file = "mods/anvil_of_destiny/files/loader_scenes/snowcastle.png",
visual_file = "",
background_file = "",
Expand Down
4 changes: 3 additions & 1 deletion files/biomes/snowcave.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for snowcave: " .. max_prob)
end

local probability = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_02, {
prob = get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene),
prob = probability,
material_file = "mods/anvil_of_destiny/files/loader_scenes/snowcave.png",
visual_file = "",
background_file = "",
Expand Down
7 changes: 5 additions & 2 deletions files/biomes/vault.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,19 @@ if probability_to_replace_pixelscene > 1 then
print("max_prob for vault: " .. max_prob)
end

local probability1 = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_01, probability_to_replace_pixelscene)
local probability2 = ANVIL_OF_DESTINY_PROB or get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene)

table.insert(g_pixel_scene_01, {
prob = get_probability_value_for_inserting(g_pixel_scene_01, probability_to_replace_pixelscene),
prob = probability1,
material_file = "mods/anvil_of_destiny/files/loader_scenes/vault_v.png",
visual_file = "",
background_file = "",
is_unique = 0
})

table.insert(g_pixel_scene_02, {
prob = get_probability_value_for_inserting(g_pixel_scene_02, probability_to_replace_pixelscene),
prob = probability2,
material_file = "mods/anvil_of_destiny/files/loader_scenes/vault_h.png",
visual_file = "mods/anvil_of_destiny/files/loader_scenes/vault_h_visual.png",
background_file = "",
Expand Down
8 changes: 4 additions & 4 deletions files/entities/anvil/anvil.xml
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@

<!-- For checking if the anvil got damaged (small area inside top part) -->

<MaterialAreaCheckerComponent
<!-- <MaterialAreaCheckerComponent
area_aabb.min_x="-3"
area_aabb.min_y="-14"
area_aabb.max_x="10"
Expand All @@ -164,11 +164,11 @@
kill_after_message="0"
look_for_failure="1"
>
</MaterialAreaCheckerComponent>
</MaterialAreaCheckerComponent> -->

<LuaComponent
<!-- <LuaComponent
script_material_area_checker_failed="mods/anvil_of_destiny/files/entities/anvil/damage_checker.lua" >
</LuaComponent>
</LuaComponent> -->

<CollisionTriggerComponent
width="78"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "anvil_of_destiny",
"version": "1.4.6",
"version": "1.4.7",
"description": "A mod for Noita (https://noitagame.com/) which adds an anvil into the default biomes, which lets you forge two wands into a new one!",
"main": "",
"scripts": {
Expand Down

0 comments on commit 66bd27f

Please sign in to comment.