Add chests, doors, and levers, and improve progressive interaction.
This commit is contained in:
parent
6439f11c2f
commit
8f98a7fa2d
18 changed files with 692 additions and 107 deletions
|
|
@ -1,14 +1,94 @@
|
|||
|
||||
local function make_lever_entity(pos)
|
||||
|
||||
end
|
||||
local levers = {}
|
||||
|
||||
minetest.register_entity(":artifact:lever_display", {
|
||||
initial_properties = {
|
||||
visual = "mesh",
|
||||
mesh = "artifact_lever.gltf",
|
||||
textures = {"artifact_lever_wood.png"},
|
||||
seelctionbox = {
|
||||
|
||||
}
|
||||
},
|
||||
_interact_time = 0.3,
|
||||
_interact_marker_offset = function(e)
|
||||
return vector.new(0, -0.4, 0):rotate(e.rotation)
|
||||
end,
|
||||
on_activate = function(e, data)
|
||||
if not minetest.get_node(e.object:get_pos()).name:find "lever" then
|
||||
e.object:remove()
|
||||
return
|
||||
end
|
||||
e.object:set_armor_groups{immortal = 1}
|
||||
extend(e, minetest.deserialize(data) or {})
|
||||
levers[e.object:get_pos():round():to_string()] = e
|
||||
end,
|
||||
on_deactivte = function(e)
|
||||
levers[e.object:get_pos():round():to_string()] = nil
|
||||
end,
|
||||
get_staticdata = function(e)
|
||||
return {rotation = e.rotation}
|
||||
end,
|
||||
on_interact = function(e)
|
||||
if e._active then
|
||||
e._active = false
|
||||
e._no_interact = true
|
||||
e.object:set_animation({x=1,y=2}, 2, 0.1, false)
|
||||
minetest.after(0.5, function()
|
||||
e._no_interact = nil
|
||||
end)
|
||||
else
|
||||
e._active = true
|
||||
e._no_interact = true
|
||||
e.object:set_animation({x=0,y=1}, 2, 0.1, false)
|
||||
minetest.after(0.5, function()
|
||||
e._no_interact = nil
|
||||
end)
|
||||
end
|
||||
end,
|
||||
rotate = function(e, rot)
|
||||
e.object:set_rotation(rot)
|
||||
e.rotation = rot
|
||||
e.object:set_properties {
|
||||
selectionbox = artifact.rotate_selectionbox({
|
||||
-3/16, -0.5, -4/16,
|
||||
3/16, -3/16, 4/16
|
||||
}, e.rotation)
|
||||
}
|
||||
end
|
||||
})
|
||||
|
||||
artifact.register_node("lever", {
|
||||
drawtype = "airlike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
paramtype2 = "facedir",
|
||||
pointable = false,
|
||||
on_construct = function(pos)
|
||||
|
||||
local m = minetest.get_meta(pos)
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
minetest.add_entity(pos, "artifact:lever_display", minetest.serialize{type = "wood"}):get_luaentity():rotate(rot)
|
||||
end,
|
||||
on_destruct = function(pos)
|
||||
levers[pos:to_string()].object:remove()
|
||||
levers[pos:to_string()] = nil
|
||||
end,
|
||||
on_load = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
-- Dynamically initialize doors that were mapgen'd in.
|
||||
if not m:contains("initialized") then
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
minetest.add_entity(pos, "artifact:lever_display", minetest.serialize{type = "wood"}):get_luaentity():rotate(rot)
|
||||
end
|
||||
end,
|
||||
on_rotate = function(pos, node, p, click, param2)
|
||||
local node = minetest.get_node(pos)
|
||||
node.param2 = param2
|
||||
minetest.swap_node(pos, node)
|
||||
local rot = minetest.facedir_to_dir(node.param2):dir_to_rotation()
|
||||
levers[pos:to_string()]:rotate(rot)
|
||||
return true
|
||||
end
|
||||
})
|
||||
|
|
|
|||
182
mods/artifact_mechanisms/chest.lua
Normal file
182
mods/artifact_mechanisms/chest.lua
Normal file
|
|
@ -0,0 +1,182 @@
|
|||
local ns = artifact
|
||||
|
||||
local chests = {}
|
||||
|
||||
minetest.register_entity(":artifact:chest_slot", {
|
||||
initial_properties = {
|
||||
static_save = false,
|
||||
visual = "mesh",
|
||||
mesh = "artifact_animator.gltf",
|
||||
selectionbox = {-0.2, -0.2, -0.2, 0.2, 0.2, 0.2}
|
||||
},
|
||||
_interact_time = 0.25,
|
||||
on_activate = function(e, item)
|
||||
e._visual = minetest.add_entity(e.object:get_pos(), "display")
|
||||
e._visual:set_properties {
|
||||
visual = "item",
|
||||
wield_item = item,
|
||||
pointable = false
|
||||
}
|
||||
e._visual:set_attach(e.object, "root")
|
||||
-- That's _one_ way to get a unique ID...
|
||||
e._name = ""..math.random()
|
||||
end,
|
||||
on_deactivate = function(e)
|
||||
e._visual:remove()
|
||||
end,
|
||||
on_hover = function(e, m)
|
||||
e.object:set_bone_override("root", {
|
||||
scale = {
|
||||
vec = vector.new(0.15, 0.15, 0.15), interpolation = 0.2, absolute = true
|
||||
},
|
||||
position = {
|
||||
vec = vector.new(0, 0.01, 0), interpolation = 0.2, absolute = true
|
||||
}
|
||||
})
|
||||
end,
|
||||
on_unhover = function(e, m)
|
||||
e.object:set_bone_override("root", {
|
||||
scale = {
|
||||
vec = vector.new(0.1, 0.1, 0.1), interpolation = 0.2, absolute = true
|
||||
},
|
||||
position = {
|
||||
vec = vector.new(0, 0.01, 0), interpolation = 0.2, absolute = true
|
||||
}
|
||||
})
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_entity(":artifact:chest_display", {
|
||||
initial_properties = {
|
||||
visual = "mesh",
|
||||
mesh = "artifact_chest.gltf",
|
||||
textures = {"artifact_chest_wood.png"},
|
||||
},
|
||||
_interact_time = 0.6,
|
||||
_interact_marker_offset = function(e)
|
||||
return vector.new(0, 0, 0.5):rotate(e.object:get_rotation())
|
||||
end,
|
||||
on_activate = function(e, data)
|
||||
if not minetest.get_node(e.object:get_pos()).name:find "chest" then
|
||||
e.object:remove()
|
||||
return
|
||||
end
|
||||
e.object:set_armor_groups{immortal = 1}
|
||||
e._pos = minetest.deserialize(data)
|
||||
chests[vector.to_string(e._pos)] = e
|
||||
end,
|
||||
on_deactivate = function(e)
|
||||
chests[vector.to_string(e._pos)] = nil
|
||||
end,
|
||||
get_staticdata = function(e)
|
||||
return minetest.serialize(e._pos)
|
||||
end,
|
||||
on_interact = function(e)
|
||||
e:open()
|
||||
end,
|
||||
on_step = function(e)
|
||||
if e._open then
|
||||
local found = false
|
||||
for obj in minetest.objects_inside_radius(e.object:get_pos(), 5) do
|
||||
if minetest.is_player(obj) then
|
||||
found = true
|
||||
break
|
||||
end
|
||||
end
|
||||
if not found then
|
||||
e:close()
|
||||
end
|
||||
end
|
||||
end,
|
||||
open = function(e)
|
||||
e._open = true
|
||||
e._no_interact = true
|
||||
e.object:set_properties{pointable = false}
|
||||
e.object:set_animation({x=0,y=0.5}, 1, 0.1, false)
|
||||
local pos = e.object:get_pos()
|
||||
local rot = e.object:get_rotation()
|
||||
e._slot_main = minetest.add_entity(pos +vector.new(0.2, 0.1, 0):rotate(rot), "artifact:chest_slot", "artifact:stone"):get_luaentity()
|
||||
e._slot_main.object:set_bone_override("root", {
|
||||
scale = {
|
||||
vec = vector.new(0.01, 0.01, 0.01), absolute = true
|
||||
},
|
||||
position = {
|
||||
vec = vector.new(0, -5, 0), absolute = true
|
||||
}
|
||||
})
|
||||
minetest.after(0, function()
|
||||
e._slot_main.object:set_bone_override("root", {
|
||||
scale = {
|
||||
vec = vector.new(0.1, 0.1, 0.1), interpolation = 0.4, absolute = true
|
||||
},
|
||||
position = {
|
||||
vec = vector.new(0, 0.01, 0), interpolation = 0.4, absolute = true
|
||||
}
|
||||
})
|
||||
end)
|
||||
e._slot_main.master = e
|
||||
e._slot_main.on_interact = function()
|
||||
|
||||
end
|
||||
e._slot_cancel = minetest.add_entity(pos +vector.new(-0.2, 0.1, 0):rotate(rot), "artifact:chest_slot", "artifact:cancel"):get_luaentity()
|
||||
e._slot_cancel.object:set_bone_override("root", {
|
||||
scale = {
|
||||
vec = vector.new(0.01, 0.01, 0.01), absolute = true
|
||||
},
|
||||
position = {
|
||||
vec = vector.new(0, -5, 0), absolute = true
|
||||
}
|
||||
})
|
||||
minetest.after(0, function()
|
||||
e._slot_cancel.object:set_bone_override("root", {
|
||||
scale = {
|
||||
vec = vector.new(0.1, 0.1, 0.1), interpolation = 0.4, absolute = true
|
||||
},
|
||||
position = {
|
||||
vec = vector.new(0, 0.01, 0), interpolation = 0.4, absolute = true
|
||||
}
|
||||
})
|
||||
end)
|
||||
e._slot_cancel.master = e
|
||||
e._slot_cancel.on_interact = function()
|
||||
e:close()
|
||||
end
|
||||
end,
|
||||
close = function(e)
|
||||
e._open = false
|
||||
e._no_interact = nil
|
||||
e.object:set_properties{pointable = true}
|
||||
e.object:set_animation({x=0.5,y=1}, 1, 0.1, false)
|
||||
e._slot_main.object:remove()
|
||||
e._slot_cancel.object:remove()
|
||||
end
|
||||
})
|
||||
|
||||
artifact.register_node("chest", {
|
||||
drawtype = "airlike",
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
pointable = false,
|
||||
groups = {call_on_load = 1},
|
||||
on_construct = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
rot.y = rot.y -math.pi
|
||||
minetest.add_entity(pos, "artifact:chest_display", minetest.serialize(pos)):set_rotation(rot)
|
||||
end,
|
||||
on_destruct = function(pos)
|
||||
chests[pos:to_string()].object:remove()
|
||||
chests[pos:to_string()] = nil
|
||||
end,
|
||||
on_load = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
-- Dynamically initialize chests that were mapgen'd in.
|
||||
if not m:contains("initialized") then
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
rot.y = rot.y -math.pi
|
||||
minetest.add_entity(pos, "artifact:chest_display", minetest.serialize(pos)):set_rotation(rot)
|
||||
end
|
||||
end
|
||||
})
|
||||
197
mods/artifact_mechanisms/doors.lua
Normal file
197
mods/artifact_mechanisms/doors.lua
Normal file
|
|
@ -0,0 +1,197 @@
|
|||
|
||||
local doors = {}
|
||||
|
||||
function artifact.rotate_selectionbox(box, rot)
|
||||
local a = vector.new(box[1], box[2], box[3]):rotate(rot)
|
||||
local b = vector.new(box[4], box[5], box[6]):rotate(rot)
|
||||
return {
|
||||
a.x, a.y, a.z,
|
||||
b.x, b.y, b.z
|
||||
}
|
||||
end
|
||||
|
||||
minetest.register_entity(":artifact:door", {
|
||||
initial_properties = {
|
||||
visual = "mesh",
|
||||
mesh = "artifact_door.gltf",
|
||||
textures = {"artifact_door_wood.png"},
|
||||
selectionbox = {
|
||||
-0.5, -0.5, -0.5,
|
||||
0.5, 1.5, -6/16
|
||||
}
|
||||
},
|
||||
_interact_time = 0.2,
|
||||
_interact_marker_offset = function(e)
|
||||
return (e._open and vector.new(-0.5, 0.5, 0) or vector.new(0, 0.5, 0.5)):rotate(e.object:get_rotation())
|
||||
end,
|
||||
on_activate = function(e, data)
|
||||
if not minetest.get_node(e.object:get_pos()).name:find "door" then
|
||||
e.object:remove()
|
||||
return
|
||||
end
|
||||
e.object:set_armor_groups{immortal = 1}
|
||||
extend(e, minetest.deserialize(data) or {})
|
||||
if e.type == "iron" and e._locked == nil then
|
||||
e._locked = true
|
||||
e.object:set_properties {
|
||||
textures = {"artifact_door_iron.png"},
|
||||
}
|
||||
end
|
||||
if e.rotation then
|
||||
e.rotation.y = e.rotation.y +math.pi
|
||||
e:rotate(e.rotation)
|
||||
end
|
||||
if e._locked then
|
||||
e._no_interact = true
|
||||
end
|
||||
e._name = ""..math.random()
|
||||
doors[e.object:get_pos():round():to_string()] = e
|
||||
end,
|
||||
on_deactivate = function(e)
|
||||
doors[e.object:get_pos():round():to_string()] = nil
|
||||
end,
|
||||
on_interact = function(e)
|
||||
if e._open then
|
||||
e._open = nil
|
||||
e._no_interact = true
|
||||
e._name = ""..math.random()
|
||||
e.object:set_animation({x=0.5,y=1}, 1.5, 0.1, false)
|
||||
minetest.after(0.1, function()
|
||||
local pos = e.object:get_pos():round()
|
||||
local node = minetest.get_node(pos)
|
||||
node.name = "door_"..e.type
|
||||
minetest.swap_node(pos, node)
|
||||
e.object:set_properties {
|
||||
selectionbox = artifact.rotate_selectionbox({
|
||||
-0.5, -0.5, -0.5,
|
||||
0.5, 1.5, -6/16
|
||||
}, e.rotation)
|
||||
}
|
||||
end)
|
||||
minetest.after(0.25, function()
|
||||
e._no_interact = nil
|
||||
end)
|
||||
else
|
||||
e._open = true
|
||||
e._no_interact = true
|
||||
e._name = ""..math.random()
|
||||
e.object:set_animation({x=0,y=0.5}, 1.5, 0.1, false)
|
||||
minetest.after(0.1, function()
|
||||
local pos = e.object:get_pos():round()
|
||||
local node = minetest.get_node(pos)
|
||||
node.name = "door_"..e.type.."_open"
|
||||
minetest.swap_node(pos, node)
|
||||
e.object:set_properties {
|
||||
selectionbox = artifact.rotate_selectionbox({
|
||||
0.5, -0.5, -0.5,
|
||||
6/16, 1.5, 0.5
|
||||
}, e.rotation)
|
||||
}
|
||||
end)
|
||||
minetest.after(0.25, function()
|
||||
e._no_interact = nil
|
||||
end)
|
||||
end
|
||||
end,
|
||||
get_staticdata = function(e)
|
||||
return minetest.serialize{type = e.type, _locked = e._locked, rotation = e.rotation}
|
||||
end,
|
||||
unlock = function(e)
|
||||
if e._locked then
|
||||
e._locked = false
|
||||
e._no_interact = nil
|
||||
end
|
||||
end,
|
||||
rotate = function(e, rot)
|
||||
e.object:set_rotation(rot)
|
||||
rot.y = rot.y -math.pi
|
||||
e.rotation = rot
|
||||
e.object:set_properties {
|
||||
selectionbox = artifact.rotate_selectionbox(e.object:get_properties().selectionbox, e.rotation)
|
||||
}
|
||||
end
|
||||
})
|
||||
|
||||
local function register_basic_door(type)
|
||||
artifact.register_node("door_"..type, {
|
||||
drawtype = "nodebox",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {
|
||||
-0.5, -0.5, -0.5,
|
||||
0.5, 1.5, -6/16
|
||||
}
|
||||
},
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"blank.png"},
|
||||
use_texture_alpha = "clip",
|
||||
paramtype = "light",
|
||||
pointable = false,
|
||||
groups = {call_on_load = 1, whackable = type == "wood" and 1 or nil},
|
||||
on_construct = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
rot.y = rot.y -math.pi
|
||||
minetest.add_entity(pos, "artifact:door", minetest.serialize{type = type}):get_luaentity():rotate(rot)
|
||||
end,
|
||||
on_destruct = function(pos, reason)
|
||||
if reason == "whack" then
|
||||
-- TODO: Particles
|
||||
end
|
||||
doors[pos:to_string()].object:remove()
|
||||
doors[pos:to_string()] = nil
|
||||
end,
|
||||
on_load = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
-- Dynamically initialize doors that were mapgen'd in.
|
||||
if not m:contains("initialized") then
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
rot.y = rot.y -math.pi
|
||||
minetest.add_entity(pos, "artifact:door", minetest.serialize{type = type}):get_luaentity():rotate(rot)
|
||||
end
|
||||
end
|
||||
})
|
||||
artifact.register_node("door_"..type.."_open", {
|
||||
drawtype = "nodebox",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {
|
||||
0.5, -0.5, -0.5,
|
||||
6/16, 1.5, 0.5
|
||||
}
|
||||
},
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"blank.png"},
|
||||
use_texture_alpha = "clip",
|
||||
paramtype = "light",
|
||||
pointable = false,
|
||||
groups = {call_on_load = 1, whackable = type == "wood" and 1 or nil},
|
||||
on_construct = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
rot.y = rot.y -math.pi
|
||||
minetest.add_entity(pos, "artifact:door", minetest.serialize{type = type}):get_luaentity():rotate(rot)
|
||||
end,
|
||||
on_destruct = function(pos)
|
||||
doors[pos:to_string()].object:remove()
|
||||
doors[pos:to_string()] = nil
|
||||
end,
|
||||
on_load = function(pos)
|
||||
local m = minetest.get_meta(pos)
|
||||
-- Dynamically initialize doors that were mapgen'd in.
|
||||
if not m:contains("initialized") then
|
||||
m:set_string("initialized", "true")
|
||||
local rot = minetest.facedir_to_dir(minetest.get_node(pos).param2):dir_to_rotation()
|
||||
rot.y = rot.y -math.pi
|
||||
minetest.add_entity(pos, "artifact:door", minetest.serialize{type = type}):get_luaentity():rotate(rot)
|
||||
end
|
||||
end
|
||||
})
|
||||
end
|
||||
|
||||
register_basic_door("wood")
|
||||
register_basic_door("iron")
|
||||
|
||||
|
|
@ -9,22 +9,10 @@ minetest.register_entity(":display", {
|
|||
end
|
||||
})
|
||||
|
||||
|
||||
|
||||
minetest.register_entity(":test", {
|
||||
initial_properties = {
|
||||
visual = "sprite",
|
||||
textures = {"blank.png"},
|
||||
use_texture_alpha = true,
|
||||
static_save = false
|
||||
},
|
||||
on_rightclick = function(e, p)
|
||||
artifact.players[p:get_player_name()].interacting_with = e
|
||||
end,
|
||||
on_hover = function() say "!" end,
|
||||
on_interact = function(e, m)
|
||||
|
||||
end
|
||||
artifact.register_craftitem("cancel", {
|
||||
inventory_image = "artifact_cancel.png"
|
||||
})
|
||||
|
||||
include "basics.lua"
|
||||
include "doors.lua"
|
||||
include "chest.lua"
|
||||
|
|
|
|||
1
mods/artifact_mechanisms/models/artifact_animator.gltf
Normal file
1
mods/artifact_mechanisms/models/artifact_animator.gltf
Normal file
|
|
@ -0,0 +1 @@
|
|||
{"asset":{"version":"2.0","generator":"Blockbench 4.12.5 glTF exporter"},"scenes":[{"nodes":[2],"name":"blockbench_export"}],"scene":0,"nodes":[{"name":"cube","mesh":0},{"name":"root","children":[0]},{"children":[1]}],"bufferViews":[{"buffer":0,"byteOffset":0,"byteLength":288,"target":34962,"byteStride":12},{"buffer":0,"byteOffset":288,"byteLength":288,"target":34962,"byteStride":12},{"buffer":0,"byteOffset":576,"byteLength":192,"target":34962,"byteStride":8},{"buffer":0,"byteOffset":768,"byteLength":72,"target":34963}],"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AAACAAEAAgADAAEABAAGAAUABgAHAAUACAAKAAkACgALAAkADAAOAA0ADgAPAA0AEAASABEAEgATABEAFAAWABUAFgAXABUA"}],"accessors":[{"bufferView":0,"componentType":5126,"count":24,"max":[0.0006250000442378223,0.6256250143051147,0.0006250000442378223],"min":[0,0.625,0],"type":"VEC3"},{"bufferView":1,"componentType":5126,"count":24,"max":[1,1,1],"min":[-1,-1,-1],"type":"VEC3"},{"bufferView":2,"componentType":5126,"count":24,"max":[0,0],"min":[0,0],"type":"VEC2"},{"bufferView":3,"componentType":5123,"count":36,"max":[23],"min":[0],"type":"SCALAR"}],"materials":[{"pbrMetallicRoughness":{"metallicFactor":0,"roughnessFactor":1},"alphaMode":"MASK","alphaCutoff":0.05,"doubleSided":true}],"meshes":[{"primitives":[{"mode":4,"attributes":{"POSITION":0,"NORMAL":1,"TEXCOORD_0":2},"indices":3,"material":0}]}]}
|
||||
1
mods/artifact_mechanisms/models/artifact_chest.gltf
Normal file
1
mods/artifact_mechanisms/models/artifact_chest.gltf
Normal file
File diff suppressed because one or more lines are too long
1
mods/artifact_mechanisms/models/artifact_door.gltf
Normal file
1
mods/artifact_mechanisms/models/artifact_door.gltf
Normal file
|
|
@ -0,0 +1 @@
|
|||
{"asset":{"version":"2.0","generator":"Blockbench 4.12.5 glTF exporter"},"scenes":[{"nodes":[2],"name":"blockbench_export"}],"scene":0,"nodes":[{"translation":[4.375,0,-4.375],"name":"cube","mesh":0},{"translation":[-4.375,0,-4.375],"name":"door","children":[0]},{"children":[1]}],"bufferViews":[{"buffer":0,"byteOffset":0,"byteLength":288,"target":34962,"byteStride":12},{"buffer":0,"byteOffset":288,"byteLength":288,"target":34962,"byteStride":12},{"buffer":0,"byteOffset":576,"byteLength":192,"target":34962,"byteStride":8},{"buffer":0,"byteOffset":768,"byteLength":72,"target":34963},{"buffer":0,"byteOffset":840,"byteLength":64},{"buffer":0,"byteOffset":904,"byteLength":256}],"buffers":[{"byteLength":1160,"uri":"data:application/octet-stream;base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AAkADAAOAA0ADgAPAA0AEAASABEAEgATABEAFAAWABUAFgAXABUAAAAAAKuqKj2rqqo9AAAAPlVVVT5VVZU+q6qqPgAAwD5VVdU+AAAAP1VVFT+rqio/AABAP1VVVT+rqmo/AACAPwAAAAAAAAAAAAAAAAAAgD8AAAAAPnsAvAAAAAD8/X8/AAAAAAQLCL0AAAAA2Nt/PwAAAABsyaW9AAAAAOsofz8AAAAAKj6FvgAAAADkLXc/AAAAAOxY/74AAAAA/eNdPwAAAABOiRa/AAAAAPUPTz8AAAAAisUlvwAAAAAxFEM/AAAAADvoLr8AAAAAie46PwAAAADzBDW/AAAAAPMENT8AAAAAriAvvwAAAACnuTo/AAAAAIrMFr8AAAAAAt9OPwAAAAAV78O+AAAAAF6DbD8AAAAAkpgevgAAAAA16Xw/AAAAABU2A70AAAAAXt5/PwAAAAAAAAAAAAAAAAAAgD8="}],"accessors":[{"bufferView":0,"componentType":5126,"count":24,"max":[5,15,5],"min":[-5,-5,3.75],"type":"VEC3"},{"bufferView":1,"componentType":5126,"count":24,"max":[1,1,1],"min":[-1,-1,-1],"type":"VEC3"},{"bufferView":2,"componentType":5126,"count":24,"max":[0.53125,1],"min":[0,0],"type":"VEC2"},{"bufferView":3,"componentType":5123,"count":36,"max":[23],"min":[0],"type":"SCALAR"},{"bufferView":4,"componentType":5126,"count":16,"max":[1],"min":[0],"type":"SCALAR"},{"bufferView":5,"componentType":5126,"count":16,"max":[0,0,0,1],"min":[0,-0.7071067690849304,0,0.7071067690849304],"type":"VEC4"}],"materials":[{"pbrMetallicRoughness":{"metallicFactor":0,"roughnessFactor":1,"baseColorTexture":{"index":0}},"alphaMode":"MASK","alphaCutoff":0.05,"doubleSided":true}],"textures":[{"sampler":0,"source":0,"name":"artifact_door_wood"}],"samplers":[{"magFilter":9728,"minFilter":9728,"wrapS":33071,"wrapT":33071}],"images":[{"mimeType":"image/png","name":"artifact_door_wood.png","uri":"artifact_door_wood.png"}],"meshes":[{"primitives":[{"mode":4,"attributes":{"POSITION":0,"NORMAL":1,"TEXCOORD_0":2},"indices":3,"material":0}]}],"animations":[{"name":"animation","samplers":[{"input":4,"output":5,"interpolation":"LINEAR"}],"channels":[{"sampler":0,"target":{"node":1,"path":"rotation"}}]}]}
|
||||
1
mods/artifact_mechanisms/models/artifact_lever.gltf
Normal file
1
mods/artifact_mechanisms/models/artifact_lever.gltf
Normal file
File diff suppressed because one or more lines are too long
BIN
mods/artifact_mechanisms/textures/artifact_cancel.png
Normal file
BIN
mods/artifact_mechanisms/textures/artifact_cancel.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 247 B |
BIN
mods/artifact_mechanisms/textures/artifact_chest_wood.png
Normal file
BIN
mods/artifact_mechanisms/textures/artifact_chest_wood.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.6 KiB |
BIN
mods/artifact_mechanisms/textures/artifact_door_iron.png
Normal file
BIN
mods/artifact_mechanisms/textures/artifact_door_iron.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 972 B |
BIN
mods/artifact_mechanisms/textures/artifact_door_wood.png
Normal file
BIN
mods/artifact_mechanisms/textures/artifact_door_wood.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 996 B |
BIN
mods/artifact_mechanisms/textures/artifact_lever_wood.png
Normal file
BIN
mods/artifact_mechanisms/textures/artifact_lever_wood.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 432 B |
Loading…
Add table
Add a link
Reference in a new issue