From dc49b4cbe5432e18b1be9293a479f44e6eb06423 Mon Sep 17 00:00:00 2001 From: Sokomine Date: Sat, 9 Sep 2023 02:56:30 +0200 Subject: [PATCH] moved mesh definiton to here from yl_speak_up --- example_npc.lua | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/example_npc.lua b/example_npc.lua index a062eb2..610743e 100644 --- a/example_npc.lua +++ b/example_npc.lua @@ -59,6 +59,26 @@ npc_talk.register_example_npc = function() end npc_talk.enable_talk_to_example_npc = function() + -- provide information about the model + yl_speak_up.mesh_data["skinsdb_3d_armor_character_5.b3d"] = { + -- the second texture is the skin + texture_index = 2, + -- they can wear and show capes and wield items + can_show_wielded_items = true, + -- call textures2skin in order to convert the textures (wielded items) + textures_to_skin = true, + animation = { + -- {x = start_frame, y = end_frame, collisionbox} + stand_still = {x = 0, y = 0, collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3}}, + stand = {x = 0, y = 79, collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3}}, + sit = {x = 81, y = 160, collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.0, 0.3}}, + lay = {x = 162, y = 166, collisionbox = {-0.6, 0.0, -0.6, 0.6, 0.3, 0.6}}, + walk = {x = 168, y = 187, collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3}}, + mine = {x = 189, y = 198, collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3}}, + walk_mine = {x = 200, y = 219, collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3}}, + }, + } + end -- TODO: may require 3darmor?