3 dofile(minetest.get_modpath("player_api") .. "/api.lua")
5 -- Default player appearance
6 player_api.register_model("character.b3d", {
8 textures = {"player.png", },
10 -- Standard animations.
11 stand = {x = 0, y = 0},
13 lay = {x = 162, y = 162},
14 walk = {x = 168, y = 187},
15 mine = {x = 189, y = 198},
16 run = {x = 189, y = 198},
17 walk_mine = {x = 200, y = 219},
18 run_mine = {x = 200, y = 219},
19 sit = {x = 81, y = 160},
20 sneak = {x = 60, y = 60},
21 sneak_mine_stand = {x=20,y=30},
22 sneak_walk= {x = 60, y = 80},
23 sneak_mine_walk= {x = 40, y = 59},
25 collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3},
30 -- Update appearance when the player joins
31 minetest.register_on_joinplayer(function(player)
32 player_api.player_attached[player:get_player_name()] = false
33 player_api.set_model(player, "character.b3d")
34 player:set_local_animation(