diff --git a/mods/default/player.lua b/mods/default/player.lua index 22cf27ef..688ef62f 100644 --- a/mods/default/player.lua +++ b/mods/default/player.lua @@ -1,55 +1,6 @@ -- Minetest 0.4 mod: player -- See README.txt for licensing and other information. ---[[ - -API ---- - -default.player_register_model(name, def) -^ Register a new model to be used by players. -^ is the model filename such as "character.x", "foo.b3d", etc. -^ See Model Definition below for format of . - -default.registered_player_models[name] -^ See Model Definition below for format. - -default.player_set_model(player, model_name) -^ is a PlayerRef. -^ is a model registered with player_register_model. - -default.player_set_animation(player, anim_name [, speed]) -^ is a PlayerRef. -^ is the name of the animation. -^ is in frames per second. If nil, default from the model is used - -default.player_set_textures(player, textures) -^ is a PlayerRef. -^ is an array of textures -^ If is nil, the default textures from the model def are used - -default.player_get_animation(player) -^ is a PlayerRef. -^ Returns a table containing fields "model", "textures" and "animation". -^ Any of the fields of the returned table may be nil. - -Model Definition ----------------- - -model_def = { - animation_speed = 30, -- Default animation speed, in FPS. - textures = {"character.png", }, -- Default array of textures. - visual_size = {x=1, y=1,}, -- Used to scale the model. - animations = { - -- = { x=, y=, }, - foo = { x= 0, y=19, }, - bar = { x=20, y=39, }, - -- ... - }, -} - -]] - -- Player animation blending -- Note: This is currently broken due to a bug in Irrlicht, leave at 0 local animation_blend = 0