Spawn von Saaten deaktiviert, um Dopplungen zu vermeiden.
This commit is contained in:
parent
f69bd7f597
commit
9dc6c712b3
58 changed files with 29 additions and 71 deletions
51
mods/.xcompat(alt)/src/player/farlands_reloaded.lua
Normal file
51
mods/.xcompat(alt)/src/player/farlands_reloaded.lua
Normal file
|
@ -0,0 +1,51 @@
|
|||
local papi = {}
|
||||
|
||||
local models = {}
|
||||
function papi.register_model(name, def)
|
||||
models[name] = def
|
||||
end
|
||||
|
||||
function papi.set_model(player, model_name)
|
||||
local model = models[model_name]
|
||||
|
||||
if not model then return end
|
||||
|
||||
player:set_properties({
|
||||
mesh = model_name,
|
||||
textures = model.textures,
|
||||
visual = "mesh",
|
||||
visual_size = model.visual_size,
|
||||
stepheight = model.stepheight
|
||||
})
|
||||
end
|
||||
|
||||
function papi.get_animation(_)
|
||||
--stub to keep from crashing
|
||||
end
|
||||
|
||||
function papi.get_textures(player)
|
||||
return player:get_properties().textures
|
||||
end
|
||||
|
||||
function papi.set_textures(player, textures)
|
||||
player:set_properties({textures = textures})
|
||||
end
|
||||
|
||||
function papi.set_animation(player, anim_name, speed, loop)
|
||||
player:set_animation(fl_player.animations[anim_name], speed, 0, loop)
|
||||
end
|
||||
|
||||
local metatable = {
|
||||
__index = function (_, key)
|
||||
return fl_player.ignore[key]
|
||||
end,
|
||||
__newindex = function (_, key, value)
|
||||
rawset(fl_player.ignore, key, value)
|
||||
end
|
||||
}
|
||||
|
||||
papi.player_attached = {}
|
||||
|
||||
setmetatable(papi.player_attached, metatable)
|
||||
|
||||
return papi
|
Loading…
Add table
Add a link
Reference in a new issue