fixes etc
This commit is contained in:
		
							parent
							
								
									4a0c8c6204
								
							
						
					
					
						commit
						453b281a4b
					
				
					 644 changed files with 1907 additions and 2456 deletions
				
			
		
							
								
								
									
										33
									
								
								resources/[standalone]/rpemotes-reborn/client/Ragdoll.lua
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								resources/[standalone]/rpemotes-reborn/client/Ragdoll.lua
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,33 @@ | |||
| if Config.RagdollEnabled then | ||||
|     RegisterCommand('+ragdoll', function() Ragdoll() end, false) | ||||
|     RegisterCommand('-ragdoll', function() StopRagdoll() end, false) | ||||
|     RegisterKeyMapping('+ragdoll', Translate('register_ragdoll'), 'keyboard', Config.RagdollKeybind) | ||||
|  | ||||
|     local isRagdolling = true | ||||
|     function Ragdoll() | ||||
|         if IsInAnimation then return end | ||||
|  | ||||
|         local ped = PlayerPedId() | ||||
|         if not IsPedOnFoot(ped) then return end | ||||
|  | ||||
|         if Config.RagdollAsToggle then | ||||
|             isRagdolling = not isRagdolling | ||||
|         else | ||||
|             isRagdolling = true | ||||
|         end | ||||
|  | ||||
|         while isRagdolling do | ||||
|             ped = PlayerPedId() | ||||
|             SetPedRagdollForceFall(ped) | ||||
|             ResetPedRagdollTimer(ped) | ||||
|             SetPedToRagdoll(ped, 1000, 1000, 3, false, false, false) | ||||
|             ResetPedRagdollTimer(ped) | ||||
|             Wait(0) | ||||
|         end | ||||
|     end | ||||
|  | ||||
|     function StopRagdoll() | ||||
|         if Config.RagdollAsToggle then return end | ||||
|         isRagdolling = false | ||||
|     end | ||||
| end | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Nordi98
						Nordi98