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


Author Topic: Assign fighing style LUA  (Read 3537 times)

0 Members and 2 Guests are viewing this topic.

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Assign fighing style LUA
« on: May 03, 2013, 08:35:16 PM »
How to assign a style for lua? I would like to use G_Melee but i dont know how to.

Offline WhenLifeGivesYouLemons

  • xfire: 1emonthatsme
  • Sr. Member
  • ***
  • Posts: 971
  • Gender: Male
  • 波動バースト
    • View Profile
Re: Assign fighing style LUA
« Reply #1 on: May 03, 2013, 08:43:25 PM »
 :)

Offline WhenLifeGivesYouLemons

  • xfire: 1emonthatsme
  • Sr. Member
  • ***
  • Posts: 971
  • Gender: Male
  • 波動バースト
    • View Profile
Re: Assign fighing style LUA
« Reply #2 on: May 03, 2013, 08:43:43 PM »
Simple  :)

PedSetActionTree(gPlayer, "Global/G_Melee_A", "Act/Anim/G_Melee_A.act")

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #3 on: May 03, 2013, 09:46:27 PM »
Thanks

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #4 on: May 03, 2013, 11:04:14 PM »
For some reason it doesnt work, i just made a new line, pasted the code and replaced it with that file.

Offline WhenLifeGivesYouLemons

  • xfire: 1emonthatsme
  • Sr. Member
  • ***
  • Posts: 971
  • Gender: Male
  • 波動バースト
    • View Profile
Re: Assign fighing style LUA
« Reply #5 on: May 03, 2013, 11:05:56 PM »
show me how your code looks like

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #6 on: May 03, 2013, 11:12:55 PM »
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)
 
  PedSetTypeToTypeAttitude(4, 13, 4)
  PedSetTypeToTypeAttitude(5, 13, 1)
  PedSetTypeToTypeAttitude(11, 13, 1)
  PedSetActionTree(gPlayer, "Global/G_Melee_A", "Act/Anim/G_Melee_A.act")
end
 
MissionCleanup = function()
end -- end statement
 
main = function() -- Main mission function
  repeat
    Wait(0)
  until l_0_0 ~= false
  Wait(3000)
  MissionSucceed()
end

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #7 on: May 03, 2013, 11:14:06 PM »
I cant move a muscle

Offline WhenLifeGivesYouLemons

  • xfire: 1emonthatsme
  • Sr. Member
  • ***
  • Posts: 971
  • Gender: Male
  • 波動バースト
    • View Profile
Re: Assign fighing style LUA
« Reply #8 on: May 03, 2013, 11:37:17 PM »
opps try /Global/ forgot the slash at the beginning lol ^_^''

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #9 on: May 03, 2013, 11:45:40 PM »
still cant move.

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)
 
  PedSetTypeToTypeAttitude(4, 13, 4)
  PedSetTypeToTypeAttitude(5, 13, 1)
  PedSetTypeToTypeAttitude(11, 13, 1)
  PedSetActionTree(gPlayer, "Global/G_Melee_A", "Act/Anim/G_Melee_A.act")
end
 
MissionCleanup = function()
end -- end statement
 
main = function() -- Main mission function
  repeat
    Wait(0)
  until l_0_0 ~= false
  Wait(3000)
  MissionSucceed()
end

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #10 on: May 03, 2013, 11:46:02 PM »
whoops forgot /

Offline DreamEvo

  • Paragon
  • Full Member
  • ***
  • Posts: 247
  • Gender: Male
    • View Profile
Re: Assign fighing style LUA
« Reply #11 on: May 03, 2013, 11:50:00 PM »
Thanks man!

Offline WhenLifeGivesYouLemons

  • xfire: 1emonthatsme
  • Sr. Member
  • ***
  • Posts: 971
  • Gender: Male
  • 波動バースト
    • View Profile
Re: Assign fighing style LUA
« Reply #12 on: May 04, 2013, 12:05:22 AM »
You' re welcome ^_^
« Last Edit: May 04, 2013, 12:08:02 AM by The Grim Peeper »