-
Notifications
You must be signed in to change notification settings - Fork 11
/
alias.lua
74 lines (65 loc) · 2.45 KB
/
alias.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
local bridger_colors = {
"Green",
"Red",
"Steel",
"White"
}
for _, color in pairs(bridger_colors) do
local oldname = color
local newname = string.lower(color)
if minetest.get_modpath("moreblocks") then
stairsplus:register_alias_all("bridges", "block_" .. oldname, "bridger", "block_" .. newname)
minetest.register_alias("bridges:step_" .. oldname, "bridger:panel_block_" .. newname)
elseif minetest.get_modpath("stairs") then
minetest.register_alias("stairs:slab_block_" .. oldname, "stairs:slab_block_" .. newname)
minetest.register_alias("stairs:stair_block_" .. oldname, "stairs:stair_block_" .. newname)
end
local bridger_error1 = {
"block_",
"step_",
"suspension_top_",
"suspension_cable_",
"deck_",
"deck_edge_",
"train_deck_",
"girder_mid_",
"girder_right_",
"truss_superstructure_right_slant_",
"truss_superstructure_left_slant_",
"small_upper_chord_",
"medium_upper_chord_",
"large_upper_chord_",
"small_support_",
"medium_support_",
"large_support_",
"truss_substructure_left_slant_",
"truss_substructure_right_slant_",
"truss_substructure_end_left_slant_",
"truss_substructure_end_right_slant_"
}
for _, prefix in pairs (bridger_error1) do
minetest.register_alias("bridges:" .. prefix .. oldname, "bridger:" .. prefix .. newname)
end
local bridger_error2 = {
"truss_substructure_mid",
"truss_substructure_simple",
"truss_superstructure_end_left_slant",
"truss_superstructure_end_right_slant",
"truss_superstructure_right_slant",
"truss_superstructure_left_slant",
"truss_superstructure_mid",
"truss_superstructure_simple",
"truss_superstructure_simple_end_right"
}
for _, prefix in pairs (bridger_error2) do
minetest.register_alias("bridges:" .. prefix .. oldname, "bridger:" .. prefix .. "_" .. newname)
end
minetest.register_alias("bridges:truss_superstructure_simple_end" .. oldname,
"bridger:truss_superstructure_simple_end_left_" .. newname)
minetest.register_alias("bridges:girder_left_end" .. oldname, "bridger:girder_left_" .. newname)
end
minetest.register_alias("bridges:corrugated_steel", "bridger:corrugated_steel_steel")
minetest.register_alias("bridges:corrugated_steel_ceiling", "bridger:corrugated_steel_ceiling_steel")
minetest.register_alias("bridges:scaffolding", "bridger:scaffolding")
minetest.register_alias("bridges:zbridges_diagonal_steel_rod", "bridger:bridges_diagonal_steel_rod")
minetest.register_alias("bridges:zbridges_steel_rod", "bridger:bridges_steel_rod")