Jump to content

[DooD]Heavyair

Members
  • Posts

    264
  • Joined

  • Last visited

Everything posted by [DooD]Heavyair

  1. if you uncompress the resource and edit the meta.xml file with notepad then scroll down to it tells u how to enable/disable certain parts ( minigun / vehicles / gravity / speed / and such )
  2. if you uncompress the resource and edit the meta.xml file with notepad then scroll down to it tells u how to enable/disable certain parts ( minigun / vehicles / gravity / speed / and such )
  3. you could allways try MTA resources page https://community.multitheftauto.com/index.php?p=resources i think this is what u need [url=https://community.multitheftauto.com/index.php?p=resources&s=details&id=43]https://community.multitheftauto.com/index.php?p= ... ails&id=43[/url] hope it helps
  4. you could allways try MTA resources page https://community.multitheftauto.com/index.php?p=resources i think this is what u need [url=https://community.multitheftauto.com/index.php?p=resources&s=details&id=43]https://community.multitheftauto.com/index.php?p= ... ails&id=43[/url] hope it helps
  5. im trying to make a ferry but when i put parts of ferry together with attach element to element the parts stack on top of each other function ferry ( player, commandname ) local bridge = createObject ( 9584, -754, 609, 5, 0, 0, 0 ) local hull = createObject ( 9585, -752, 609, -4, 0, 0, 0 ) local deck = createObject ( 9586, -827, 609, 14, 0, 0, 0.5 ) attacheElementToElement ( bridge, deck, 73, 0, 0, 0, 0, -0.5 ) attachElementToElement ( deck, hull, 75, 0, 18, 0, 0, 0.5 )end addCommandHandler ( "ferry", ferry ) not sure how to get the offset coordinates right / also not sure how to upload screenshot i also get an error on attach element to element line 5 attempt to call global attach element to element nil value i have tried this with no offset coordinates but it does the same thing any ideas appreciated
  6. im trying to make a ferry but when i put parts of ferry together with attach element to element the parts stack on top of each other function ferry ( player, commandname ) local bridge = createObject ( 9584, -754, 609, 5, 0, 0, 0 ) local hull = createObject ( 9585, -752, 609, -4, 0, 0, 0 ) local deck = createObject ( 9586, -827, 609, 14, 0, 0, 0.5 ) attacheElementToElement ( bridge, deck, 73, 0, 0, 0, 0, -0.5 ) attachElementToElement ( deck, hull, 75, 0, 18, 0, 0, 0.5 ) end addCommandHandler ( "ferry", ferry ) not sure how to get the offset coordinates right / also not sure how to upload screenshot i also get an error on attach element to element line 5 attempt to call global attach element to element nil value i have tried this with no offset coordinates but it does the same thing any ideas appreciated
  7. if u know how to script its not to hard to do this personally im not very good but if u need someone to write it for u i can give it a go ( should be fairly simple ) i just need u to tell me where u want the object ( go to where u want it and open console type getpos ) if u just want suggestions i read in a post around here somewhere that easiest way is to use map editor ( theres a couple on MTA resources page ) put the object where u want it when its down and then make another where u want it when its up and write a move object function to move between the two sets of coordinates and use a collision shape to trigger the movement i have been working on a few things and with help from others on the forum i know how to do all the things u will need or i can probably talk u through it
  8. if u know how to script its not to hard to do this personally im not very good but if u need someone to write it for u i can give it a go ( should be fairly simple ) i just need u to tell me where u want the object ( go to where u want it and open console type getpos ) if u just want suggestions i read in a post around here somewhere that easiest way is to use map editor ( theres a couple on MTA resources page ) put the object where u want it when its down and then make another where u want it when its up and write a move object function to move between the two sets of coordinates and use a collision shape to trigger the movement i have been working on a few things and with help from others on the forum i know how to do all the things u will need or i can probably talk u through it
  9. u need to post a serial request in here i think https://forum.multitheftauto.com/viewtopic.php?f=89&t=21435
  10. u need to post a serial request in here i think https://forum.multitheftauto.com/viewtopic.php?f=89&t=21435
  11. not to sure about VISTA problems but if youve got a router u need to forward ports ive explained it to a few people so just search forums for router or forward ports
  12. not to sure about VISTA problems but if youve got a router u need to forward ports ive explained it to a few people so just search forums for router or forward ports
  13. there are a couple of user made map editors on the MTA resource page here u go https://community.multitheftauto.com/index.php?p=resources
  14. there are a couple of user made map editors on the MTA resource page here u go https://community.multitheftauto.com/index.php?p=resources
  15. probably a problem at the server end if your running a private server ( on pc at home ) u get that error if the ports on your royter havent been forawrded or if u have a firewall blocking access
  16. probably a problem at the server end if your running a private server ( on pc at home ) u get that error if the ports on your royter havent been forawrded or if u have a firewall blocking access
  17. ive gotta learn all this syntax stuff that objectID in map file has messed up quite a few things ive been trying to do thanx so much ace_gambit EDIT : with the map file entry i found u only need one "object" <object id="lossamsite" model="3885" posX="-711" posY="957" posZ="30" rotX="0" rotY="0" rotZ="0"/> map is workin now just gotta get the rest now just dont seem to be able to make sense of this for some reason i know what i want it to do but i just cant figure it out i have looked at a few lua tutorials and they make perfect sense but they dont tell me what i need i understand how the function works ( just about ) but i just cant figure out how to implement it i thought if i told the function what the sam site is oSAM = getElementByID("lossam") -- SAM site object i put object id "lossam" in the map file so it gets any samsites ive made in the map file but i dont understand how to make the ( testTargetAngleAgainstLoS ) function attach to the sam sites so it knows where to look for the target and then trigger the firing event i thought that the getElementByID would make the function work for all sam sites made with the map file but when i fly around the sam site i dont get the Uh-Oh message sorry about taking up so much of your time ace_gambit as i dont seem to be getting very far with this scripting stuff i really dont know what else to try to get a better understanding of how lua works because just looking at the scripts and stuff seems to make me even more confused i think i understand most of the functions but just dont know how to tie them all together im going to try the wiki again and see if theres any better tutorials out there EDIT ::: EDIT ::: ace_gambit i have tried running the script u put above oSAM = getElementByID("lossamsite") -- SAM site object previousTick = getTickCount() function testTargetAngleAgainstLoS(source, target, traceAngle, minDepth, maxDepth, minOffsetZ, maxOffsetZ) local oX, oY, oZ = getElementPosition(source) local rotX, rotY, rotZ = getObjectRotation(source) local tX, tY, tZ = getElementPosition(target) local targetDist2D = getDistanceBetweenPoints2D(oX, oY, tX, tY) local losX, losY, losZ = oX, oY, oZ local btX, btY, btZ = oX, oY, oZ local btDist2D = 0 local pX2D, pY2D = 0, 0 local pDist2D = 0 local ptotDist2D = 0 local angle = 0 if (targetDist2D < minDepth or targetDist2D > maxDepth or tZ < (oZ - minOffsetZ) or tZ > (oZ + maxOffsetZ)) then return end losX = losX - math.sin(math.rad(rotZ)) * targetDist2D losY = losY + math.cos(math.rad(rotZ)) * targetDist2D btX = btX - math.sin(math.rad(rotZ + 180)) * targetDist2D btY = btY + math.cos(math.rad(rotZ + 180)) * targetDist2D btDist2D = getDistanceBetweenPoints2D(btX, btY, tX, tY) if (tX > losX) then pX2D = tX - (math.abs(tX - losX) / 2) else pX2D = losX - (math.abs(losX - tX) / 2) end if (tY > losY) then pY2D = tY - (math.abs(tY - losY) / 2) else pY2D = losY - (math.abs(losY - tY) / 2) end pDist2D = getDistanceBetweenPoints2D(oX, oY, pX2D, pY2D) ptotDist2D = getDistanceBetweenPoints2D(pX2D, pY2D, tX, tY) angle = math.deg(math.tan(ptotDist2D / pDist2D)) * 2 return (angle > 0 and angle < traceAngle and targetDist2D < btDist2D) end function callbackClientRender() if (testTargetAngleAgainstLoS(oSAM, getLocalPlayer(), 35, 15, 100, 5, 200) and getTickCount() > (previousTick + 1500)) then previousTick = getTickCount() outputChatBox("Uh-oh") end end addEventHandler("onClientRender", getRootElement(), callbackClientRender) i thought it would give me the Uh oH message when i went around the lossamite object oSAM = getElementByID("lossamsite") -- SAM site object but nothing im really sorry but i have been looking at assorted tutorials and the wiki but i just dont get it do u have any idea if i will be able to move the collision shapes when DP3 is done thanx for all your help but i think i will just have to keep things simple for a while longer yet
  18. ive gotta learn all this syntax stuff that objectID in map file has messed up quite a few things ive been trying to do thanx so much ace_gambit EDIT : with the map file entry i found u only need one "object" map is workin now just gotta get the rest now just dont seem to be able to make sense of this for some reason i know what i want it to do but i just cant figure it out i have looked at a few lua tutorials and they make perfect sense but they dont tell me what i need i understand how the function works ( just about ) but i just cant figure out how to implement it i thought if i told the function what the sam site is oSAM = getElementByID("lossam") -- SAM site object i put object id "lossam" in the map file so it gets any samsites ive made in the map file but i dont understand how to make the ( testTargetAngleAgainstLoS ) function attach to the sam sites so it knows where to look for the target and then trigger the firing event i thought that the getElementByID would make the function work for all sam sites made with the map file but when i fly around the sam site i dont get the Uh-Oh message sorry about taking up so much of your time ace_gambit as i dont seem to be getting very far with this scripting stuff i really dont know what else to try to get a better understanding of how lua works because just looking at the scripts and stuff seems to make me even more confused i think i understand most of the functions but just dont know how to tie them all together im going to try the wiki again and see if theres any better tutorials out there EDIT ::: EDIT ::: ace_gambit i have tried running the script u put above oSAM = getElementByID("lossamsite") -- SAM site objectpreviousTick = getTickCount() function testTargetAngleAgainstLoS(source, target, traceAngle, minDepth, maxDepth, minOffsetZ, maxOffsetZ) local oX, oY, oZ = getElementPosition(source) local rotX, rotY, rotZ = getObjectRotation(source) local tX, tY, tZ = getElementPosition(target) local targetDist2D = getDistanceBetweenPoints2D(oX, oY, tX, tY) local losX, losY, losZ = oX, oY, oZ local btX, btY, btZ = oX, oY, oZ local btDist2D = 0 local pX2D, pY2D = 0, 0 local pDist2D = 0 local ptotDist2D = 0 local angle = 0 if (targetDist2D < minDepth or targetDist2D > maxDepth or tZ < (oZ - minOffsetZ) or tZ > (oZ + maxOffsetZ)) then return end losX = losX - math.sin(math.rad(rotZ)) * targetDist2D losY = losY + math.cos(math.rad(rotZ)) * targetDist2D btX = btX - math.sin(math.rad(rotZ + 180)) * targetDist2D btY = btY + math.cos(math.rad(rotZ + 180)) * targetDist2D btDist2D = getDistanceBetweenPoints2D(btX, btY, tX, tY) if (tX > losX) then pX2D = tX - (math.abs(tX - losX) / 2) else pX2D = losX - (math.abs(losX - tX) / 2) end if (tY > losY) then pY2D = tY - (math.abs(tY - losY) / 2) else pY2D = losY - (math.abs(losY - tY) / 2) end pDist2D = getDistanceBetweenPoints2D(oX, oY, pX2D, pY2D) ptotDist2D = getDistanceBetweenPoints2D(pX2D, pY2D, tX, tY) angle = math.deg(math.tan(ptotDist2D / pDist2D)) * 2 return (angle > 0 and angle < traceAngle and targetDist2D < btDist2D)end function callbackClientRender() if (testTargetAngleAgainstLoS(oSAM, getLocalPlayer(), 35, 15, 100, 5, 200) and getTickCount() > (previousTick + 1500)) then previousTick = getTickCount() outputChatBox("Uh-oh") endend addEventHandler("onClientRender", getRootElement(), callbackClientRender) i thought it would give me the Uh oH message when i went around the lossamite object oSAM = getElementByID("lossamsite") -- SAM site object but nothing im really sorry but i have been looking at assorted tutorials and the wiki but i just dont get it do u have any idea if i will be able to move the collision shapes when DP3 is done thanx for all your help but i think i will just have to keep things simple for a while longer yet
  19. [DooD]Heavyair

    map editor

    there is something called the DELUXE MTA MAP CONVERTER for MIRC it was posted in the forum but im not sure where its gone its a little bit complicated but not to bad ( cant find it at the moment but will post it for u when i do ) i have the file u need but im not sure how to put it on the forum as its on my system and it wont let me attach mrc files will get it to u as soon as i can
  20. [DooD]Heavyair

    map editor

    there is something called the DELUXE MTA MAP CONVERTER for MIRC it was posted in the forum but im not sure where its gone its a little bit complicated but not to bad ( cant find it at the moment but will post it for u when i do ) i have the file u need but im not sure how to put it on the forum as its on my system and it wont let me attach mrc files will get it to u as soon as i can
  21. i think im beginning to understand this now i will see what i can do and post any decent results THANX ACE_GAMBIT with the oSAM = getElementByID("bla bla") -- SAM site object line do i just put the objectID of what im using for the sam site i assume that it would then run the line of sight check on all my sam sites well ill give it a go and see what happens sorry takin up so much of your time ace_gambit but now im really confused i cant seem to figure out how to use this in a script with the oSAM = getElementByID("bla bla") -- SAM site object line i looked at the wiki and it says getElementByID will look for the objectID stated in the .map file but when i have created objects with the .map file before i messed up the objectID part <object model="4866" posX="-542.96350097656" posY="886.63665771484" posZ="2.7947807312012" rotX="0.5" rotY="0.5" rotZ="75"/> this is how i put in objects and this is how i do vehicles <vehicle id="BladeBackShed" model="536" posX="-676.43225097656" posY="962.98449707031" posZ="12.507791519165" rotX="0.041015625" rotY="0.002777099609375" rotZ="92.063659667969" upgrades="1010 1087 1104 1103 1107 1108 1181 1183" paintjob="1" plate="PIMPED"/> but from what i can see in the wiki i need to give the objects an ID like samsite1 or something but when ive tried to do this in the past the map file wont load | | <objectID="samsite1" object model="4866" posX="-542.96350097656" posY="886.63665771484" posZ="2.7947807312012" rotX="0.5" rotY="0.5" rotZ="75"/> so im not sure how to tell the function what it should calculate the line of sight for again i hope that makes sense edit ; suddenly feel stupid looking at second script i think if i set oSAM to createObject( sam site stuff ) it should set where the source is and then set target as getLocalPlayer will give me the target going to try it now back soon thank u very very much for your PATIENCE AND HELP u r great EDIT 2 : still no joy i think im going to look for some lua tutorials and see if i can expand my knowledge a bit because is beyond me at the moment but I'LL BE BACK
  22. i think im beginning to understand this now i will see what i can do and post any decent results THANX ACE_GAMBIT with the oSAM = getElementByID("bla bla") -- SAM site object line do i just put the objectID of what im using for the sam site i assume that it would then run the line of sight check on all my sam sites well ill give it a go and see what happens sorry takin up so much of your time ace_gambit but now im really confused i cant seem to figure out how to use this in a script with the oSAM = getElementByID("bla bla") -- SAM site object line i looked at the wiki and it says getElementByID will look for the objectID stated in the .map file but when i have created objects with the .map file before i messed up the objectID part this is how i put in objects and this is how i do vehicles but from what i can see in the wiki i need to give the objects an ID like samsite1 or something but when ive tried to do this in the past the map file wont load | | so im not sure how to tell the function what it should calculate the line of sight for again i hope that makes sense edit ; suddenly feel stupid looking at second script i think if i set oSAM to createObject( sam site stuff ) it should set where the source is and then set target as getLocalPlayer will give me the target going to try it now back soon thank u very very much for your PATIENCE AND HELP u r great EDIT 2 : still no joy i think im going to look for some lua tutorials and see if i can expand my knowledge a bit because is beyond me at the moment but I'LL BE BACK
×
×
  • Create New...