• Animation Refuses To Play (is this function broken?)
    2 replies, posted
I have done this, in the shared.lua for my gamemode. Keep in mind this is the only code in shared.lua: [lua] function GM:CalcMainActivity(ply) local sequence = ply:LookupSequence( "harrassalert" ) --i am able to play said sequence just fine with: ply:SetSequence(sequence, true) --also playing gestures with the AddLayeredSequence function does not work either --so here is the code that doesnt work if (!SERVER) then return true, -1 end; local seqid = ply:AddLayeredSequence(sequence, 100); return true, -1; end function GM:TranslateActivity() end function GM:DoAnimationEvent(ply) end function GM:UpdateAnimation(ply) end function GM:GrabEarAnimation( ply ) end function GM:MouthMoveAnimation( ply ) end function GM:HandlePlayerJumping( ply, velocity ) end function GM:HandlePlayerDucking( ply, velocity ) end function GM:HandlePlayerNoClipping( ply, velocity ) end function GM:HandlePlayerVaulting( ply, velocity ) end function GM:HandlePlayerSwimming( ply, velocity ) end function GM:HandlePlayerLanding( ply, velocity, WasOnGround ) end function GM:HandlePlayerDriving( ply ) end [/lua] Nothing plays. I remain in a T-Pose. I have been trying to get this to work for months upon months. I've put this code and very similar code in many many places, nothing has worked... I just don't understand. I am thinking the function itself may be straight-up completely broken at this point. Why... just why? Why is it so hard to get the animation to play and how do I do it? Has anyone in the entire GMod community even used this function once? All I'm trying to do is control an animation's weight. That's it. Just like in HLMV. Right there is exactly what I want. But it's not working here in GMod...
If you overwrite the default animations how do you expect them to work?
I don't want to use the default animations, because I'm working with players that are using NPC models. I'm trying to play an animation layer and control it's weight.
Sorry, you need to Log In to post a reply to this thread.