Add setting for tail enabled, PM manage cape
Move cape to PartsManager so it can be disabled when tail is enabled
This commit is contained in:
parent
a0097ff86d
commit
6b64bc0a13
25
script.lua
25
script.lua
@ -209,6 +209,7 @@ do
|
|||||||
["snore_enabled"]=true,
|
["snore_enabled"]=true,
|
||||||
["print_settings"]=false,
|
["print_settings"]=false,
|
||||||
["vanilla_partial"]=false,
|
["vanilla_partial"]=false,
|
||||||
|
["tail_enabled"]=true,
|
||||||
["aquatic_enabled"]=false
|
["aquatic_enabled"]=false
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -377,34 +378,37 @@ do
|
|||||||
|
|
||||||
--- Vanilla state
|
--- Vanilla state
|
||||||
-- Show all in vanilla partial
|
-- Show all in vanilla partial
|
||||||
PM.addPartGroupFunction(VANILLA_GROUPS.ALL, function() return
|
PM.addPartGroupFunction(VANILLA_GROUPS.ALL, function() return vanillaPartial() end)
|
||||||
vanillaPartial() end)
|
-- no cape if tail enabled (it clips)
|
||||||
-- no legs in water if tail enabled
|
PM.addPartFunction(vanilla_model.CAPE, function(last) return last and not local_state.tail_enabled end)
|
||||||
|
-- no legs in water if mtail enabled
|
||||||
PM.addPartGroupFunction(VANILLA_GROUPS.LEFT_LEG, function(last) return last and not aquaticTailVisible() end)
|
PM.addPartGroupFunction(VANILLA_GROUPS.LEFT_LEG, function(last) return last and not aquaticTailVisible() end)
|
||||||
PM.addPartGroupFunction(VANILLA_GROUPS.RIGHT_LEG, function(last) return last and not aquaticTailVisible() end)
|
PM.addPartGroupFunction(VANILLA_GROUPS.RIGHT_LEG, function(last) return last and not aquaticTailVisible() end)
|
||||||
-- no vanilla head in partial vanilla
|
-- no vanilla head in partial vanilla
|
||||||
PM.addPartGroupFunction(VANILLA_GROUPS.HEAD, function(last)
|
PM.addPartGroupFunction(VANILLA_GROUPS.HEAD, function(last)
|
||||||
return last and not vanillaPartial() end)
|
return last and not vanillaPartial() end)
|
||||||
-- Always true if vanilla_enabled
|
-- Always true if vanilla_enabled
|
||||||
PM.addPartGroupFunction(VANILLA_GROUPS.ALL,
|
PM.addPartGroupFunction(VANILLA_GROUPS.ALL, function(last) return last or local_state.vanilla_enabled end)
|
||||||
function(last) return last or local_state.vanilla_enabled end)
|
|
||||||
|
|
||||||
--- Armor state
|
--- Armor state
|
||||||
PM.addPartGroupFunction(VANILLA_GROUPS.ARMOR,
|
PM.addPartGroupFunction(VANILLA_GROUPS.ARMOR, function(last) return local_state.armor_enabled end)
|
||||||
function(last) return local_state.armor_enabled end)
|
|
||||||
|
|
||||||
--- Custom state
|
--- Custom state
|
||||||
-- Disable model in vanilla partial
|
-- Disable model in vanilla partial
|
||||||
PM.addPartGroupFunction(CUSTOM_GROUPS, function(last) return not vanillaPartial() end)
|
PM.addPartGroupFunction(CUSTOM_GROUPS, function(last) return not vanillaPartial() end)
|
||||||
|
-- Enable certain parts in vanilla partial
|
||||||
|
local vanilla_partial_enabled={model.Head, model.Body_Tail}
|
||||||
|
PM.addPartGroupFunction(vanilla_partial_enabled, function(last) return last or vanillaPartial() end)
|
||||||
|
-- Enable tail setting
|
||||||
|
PM.addPartFunction(model.Body_Tail, function(last) return last and local_state.tail_enabled end)
|
||||||
-- no legs, regular tail in water if tail enabled
|
-- no legs, regular tail in water if tail enabled
|
||||||
local mtail_mutually_exclusive={model.LeftLeg, model.RightLeg, model.Body_Tail}
|
local mtail_mutually_exclusive={model.LeftLeg, model.RightLeg, model.Body_Tail}
|
||||||
PM.addPartGroupFunction(mtail_mutually_exclusive, function(last) return last and not aquaticTailVisible() end)
|
PM.addPartGroupFunction(mtail_mutually_exclusive, function(last) return last and not aquaticTailVisible() end)
|
||||||
|
|
||||||
-- Enable certain parts in vanilla partial
|
|
||||||
local vanilla_partial_enabled={model.Head, model.Body_Tail}
|
|
||||||
PM.addPartGroupFunction(vanilla_partial_enabled, function(last) return last or vanillaPartial() end)
|
|
||||||
-- Disable when vanilla_enabled
|
-- Disable when vanilla_enabled
|
||||||
PM.addPartGroupFunction(CUSTOM_GROUPS, function(last) return last and not local_state.vanilla_enabled end)
|
PM.addPartGroupFunction(CUSTOM_GROUPS, function(last) return last and not local_state.vanilla_enabled end)
|
||||||
|
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
SNORES={"snore-1", "snore-2", "snore-3"}
|
SNORES={"snore-1", "snore-2", "snore-3"}
|
||||||
@ -593,7 +597,6 @@ else
|
|||||||
v.setEnabled(false)
|
v.setEnabled(false)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
vanilla_model.CAPE.setEnabled(true)
|
|
||||||
|
|
||||||
-- }}}
|
-- }}}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user