Tete omar Posted June 2, 2012 Posted June 2, 2012 How do i make any thing like the bag of money , or any object like the weapons the player can carry the weapons i want the player carry a pickup like the CJ_SANDBAG
Castillo Posted June 2, 2012 Posted June 2, 2012 You can use this resource: https://community.multitheftauto.com/ind ... ls&id=2540 San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Tete omar Posted June 2, 2012 Author Posted June 2, 2012 You can use this resource:https://community.multitheftauto.com/ind ... ls&id=2540 Can't understand how this this thing works .
Castillo Posted June 2, 2012 Posted June 2, 2012 It's like the function: attachElements but for Bones. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Tete omar Posted June 2, 2012 Author Posted June 2, 2012 You mean just like that if ( source == GUIEditor_Button[3] ) then local Marker = createMarker ( -8.8994140625, 51.5, 2.0999999046326, "cylinder", 1.10000002, 255, 29, 91, 1 ) addEventHandler('onClientMarkerHit', Marker,function(hitPlayer) if (hitPlayer == localPlayer) then attachElementToBone(Marker,localPlayer,CJ_SANDBAG,-8.8994140625,51.5,2.0999999046326,1.9986572265625,177.99884033203,30.069580078125) alright ?
Castillo Posted June 2, 2012 Posted June 2, 2012 You gotta use the exported function correctly: exports [ "bone_attach" ]:attachElementToBone ( arguments ) San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Tete omar Posted June 2, 2012 Author Posted June 2, 2012 You gotta use the exported function correctly: exports [ "bone_attach" ]:attachElementToBone ( arguments ) Sorry if i'm too dumb but can you give me an example please.
Alexs Posted June 3, 2012 Posted June 3, 2012 local Marker = createMarker ( -8.8994140625, 51.5, 2.0999999046326, "cylinder", 1.10000002, 255, 29, 91, 1 ) local sandbag = createObject ( 2060, 0, 0, 0, 0, 0, 0 ) function pegarsaco (hitPlayer) if (hitPlayer == localPlayer) then exports.bone_attach:attachElementToBone ( sandbag, hitPlayer, 12, 0, 0, 0, 0 , 0, 0 ) end end addEventHandler('onClientMarkerHit', Marker, pegarsaco) Developer @ MYVAL
X-SHADOW Posted June 3, 2012 Posted June 3, 2012 Alexs_Steel why use if ( hitPlayer == localPlayer) ? My ingame nickname : Ops! -DeathMatch GameMode By Ops! : 5%
Alexs Posted June 3, 2012 Posted June 3, 2012 Alexs_Steel why use if ( hitPlayer == localPlayer) ? i dont know, but i use it and works Developer @ MYVAL
Castillo Posted June 3, 2012 Posted June 3, 2012 Alexs_Steel why use if ( hitPlayer == localPlayer) ? So if a remote client hits that marker, it'll not execute your code. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Castillo Posted June 3, 2012 Posted June 3, 2012 You're welcome. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now