Features
Exports
Client Exports

Client Exports

Get Animations

-- return: table - returns formatted animations
 
local config = exports["bablo-animations"]:getAnimations()

Reset Clipset/Walkingstyle

exports["bablo-animations"]:resetClipset()

Open Menu

exports["bablo-animations"]:openApp()

Play Animation

-- ped: number - the ped thats going to play the anim
-- animationName: string - name of the animation
 
exports["bablo-animations"]:playAnimation(ped, animationName)

Cancel Animation

exports["bablo-animations"]:cancelAnimation()

Get Animation

-- animationName: string - name of the animation
-- return: table - returns animationData from config
 
exports["bablo-animations"]:getAnimation(animationName)

Can Access

-- return: bool - returns if player is able to open menu
 
exports["bablo-animations"]:canAccess()

Set Access

-- state: bool - define the state that determines if the player can access the menu.
 
exports["bablo-animations"]:setAccess(state)

Set Cached Walkingstyle

exports["bablo-animations"]:setWalkingstyle()

Set Cached Expression

exports["bablo-animations"]:setExpression()

Check If Menu Is Open

exports["bablo-animations"]:isMenuOpen()

Disable Cancel Animation

-- state: bool - define the state that determines if you are able cancel or not.
 
exports["bablo-animations"]:disableCancelAnimation(state)

Can Cancel Animaiton

Is Animation Being Played

-- return what animations is being played or false if no animation is being played
 
LocalPlayer.state.isInAnimation

Play Emote With Data

-- Play animation with raw data
exports['bablo-animations']:playEmoteData({
    "anim@heists@box_carry@",  -- [1] Animation dictionary
    "idle",                     -- [2] Animation name  
    "Food Tray D",              -- [3] Label (optional)
    animationOptions = {
        prop = "prop_food_tray_02",
        propBone = 28422,
        propPlacement = {0.0100, -0.0400, -0.1390, 20.0, 0.0, 0.0},
        emoteLoop = true,
        emoteMoving = true
    }
})

Disable Modules

 
-- disable: bool - true to disable all modules, false to enable them again disables crouch, prone, pointing, hands up
 
exports['bablo-animations']:disableModules(true) -- Disable all modules