News: Welcome back to Bullworth! If you haven't already, you will need to reset your password..


Author Topic: Anyone have the code strafe Luis Juri or bone that moves and fighting style?  (Read 1262 times)

0 Members and 1 Guest are viewing this topic.

Offline bullymodder74

  • Jr. Member
  • **
  • Posts: 51
  • Gender: Male
  • Bully Mods
    • View Profile
someone has it?

Offline barca769

  • Jr. Member
  • **
  • Posts: 25
  • Gender: Male
  • Never Ending
    • View Profile
Please Bullymodder74 can you make all question in one thread?

Here the code :
Code: [Select]
ImportScript("\\Library\\LibTable.lua") -- imports the LibTable library
ImportScript("\\Library\\LibPed.lua") -- imports the LibPed library
local l_0_0 = false
 
MissionSetup = function() -- basic mission setup function which is used in almost all bully scripts
  local l_1_0 = 270 -- X coords
  local l_1_1 = -110 -- Y coords
  local l_1_2 = 6.4000000953674 -- Z coords
 
  PlayerSetHealth(200) -- gives the player 200 health
  AreaTransitionXYZ(0, l_1_0, l_1_1, l_1_2)
 
end
 
MissionCleanup = function()
end -- end statement
 
main = function() -- Main mission function
  LoadAnimationGroup("J_Grappler")
  repeat
F_Strafe()
    Wait(0)
  until l_0_0 ~= false
  Wait(3000)
  MissionSucceed()
end


F_Strafe = function()
  if IsButtonPressed(10,0) and IsMoving() and not isStrafing and not PedIsValid(PedGetGrappleTargetPed(gPlayer)) then
    PedSetActionNode(gPlayer,"/Global/J_Grappler_A/Default_KEY/ExecuteNodes/LocomotionOverride/Combat/CombatBasic","Act/Anim/J_Grappler_A.act")
   isStrafing = true
  elseif (not IsButtonPressed(10,0) or not IsMoving()) and isStrafing and not PedIsValid(PedGetGrappleTargetPed(gPlayer)) then
   PedSetActionTree(gPlayer,"/Global/J_Grappler_A","Act/Anim/J_Grappler_A.act")
   isStrafing = false
  elseif isStrafing then
   local x,y,z = PedGetPosXYZ(PedGetTargetPed())
   PedFaceXYZ(gPlayer,x,y,z)
  end
end

This Can make Player Strafe like Juri and Luis with fighting style (but not full fighting style)
Remember..! Copy the code :)
« Last Edit: September 22, 2015, 11:37:26 AM by barca769 »