Quiz Posted December 31, 2012 Share Posted December 31, 2012 Hi guys, I have a small question. When I attach an object to another using attachElements I can't walk quickly on these objects. Is there any solution for this?? Link to comment
GhostXoP Posted December 31, 2012 Share Posted December 31, 2012 Depends, what are you attaching? Link to comment
Quiz Posted December 31, 2012 Author Share Posted December 31, 2012 I tried to attach parts of a ship togother, but I can't walk quickly on these parts after the attachment. Link to comment
Quiz Posted December 31, 2012 Author Share Posted December 31, 2012 Hey guys, are you there or what??!!! Why no body answer my question???! Link to comment
Perfect Posted December 31, 2012 Share Posted December 31, 2012 maybe you did'nt attach them correctly ? Link to comment
TAPL Posted December 31, 2012 Share Posted December 31, 2012 Maybe you need this: setElementCollidableWith Link to comment
Quiz Posted December 31, 2012 Author Share Posted December 31, 2012 Maybe you need this: setElementCollidableWith I know how to use this function, it's for controlling the the status of the collision between the objects and this is not what I want! Try to create two objects and then attach them together you'll see that you can't walk quickly on the object which is attached. Link to comment
TAPL Posted December 31, 2012 Share Posted December 31, 2012 Post your code, i want try. Link to comment
Quiz Posted December 31, 2012 Author Share Posted December 31, 2012 local object = createObject(8838,2490,-1670,13.9) local object1 = createObject(8838,2490,-1670,17.9) addEventHandler( "onClientResourceStart", getRootElement( ), function() attachElements (object1,object, 0, 5, 0 ) end) try to walk quickly on the first object, you'll see that you can. But you can't do the same thing with the second one. Link to comment
TAPL Posted December 31, 2012 Share Posted December 31, 2012 LoL, this really strange. This is bug, should be reported at: http://bugs.multitheftauto.com Link to comment
Quiz Posted December 31, 2012 Author Share Posted December 31, 2012 LoL, this really strange.This is bug, should be reported at: http://bugs.multitheftauto.com Lol, please report it then, I don't know how I, and even everybody here, want a solution as soon as possible. Link to comment
TAPL Posted December 31, 2012 Share Posted December 31, 2012 Right now you can do this solution maybe. local object = createObject(8838, 2490, -1670, 13.9) local object1 = createObject(8838, 2490, -1670, 17.9) addEventHandler("onClientResourceStart", resourceRoot, function() attachElements(object1, object, 0, 5, 0) setTimer(detachElements, 200, 1, object1, object) end) Link to comment
Quiz Posted December 31, 2012 Author Share Posted December 31, 2012 Right now you can do this solution maybe. local object = createObject(8838, 2490, -1670, 13.9) local object1 = createObject(8838, 2490, -1670, 17.9) addEventHandler("onClientResourceStart", resourceRoot, function() attachElements(object1, object, 0, 5, 0) setTimer(detachElements, 200, 1, object1, object) end) lol, this not a solution because I want to use moveObject on the main object to make both objects moving together. Another thing I want to mention it, If you attach an object to another (like my code), and then use moveObject to make the main object moving. If you were standing on the second one (the attached one), you would fall to the ground. You have to stand on the main object if you don't want to fall. Try it and you'll see. Link to comment
Gr0x Posted December 31, 2012 Share Posted December 31, 2012 Maybe this? attachElements(object1,object,0,5,0) setTimer(detachElements,200,1,object1,object) setElementParent(object1,object) moveObject(object,...) Link to comment
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