# Timiimit

Members

142

## Community Reputation

0 Neutral

• Rank
Poot-butt
• Birthday 29/03/1913

• Gang
[GFL]

thx!

thx!
3. ## 4 wheel landing

i did: function checkLanding (hitElement, force, bodypart, colX, colY, colZ, normX, normY, normZ) if(source ~= veh)then return end local m = getElementMatrix(veh) local vecX, vecY, vecZ = m[3][1], m[3][2], m[3][3] local nRot = 0.05 if math.abs(vecX - normX) <= nRot and math.abs(vecY - normY) <= nRot and math.abs(vecZ - normZ) <= nRot then outputChatBox("landed like a boss!") end end and i get 0-2 outputs (depends on the speed) when i'm not even in the air yet (still on ramp or when ground angle changes) and 1-3 outputs when i land.
4. ## 4 wheel landing

this is what i got: function checkLanding (hitElement, force, bodypart, colX, colY, colZ, normX, normY, normZ) if(source ~= veh)then return end local m = getElementMatrix(veh) local vecX, vecY, vecZ = m[3][1], m[3][2], m[3][3] local nRot = 8 if not wasOnGround and (vecZ - normZ <= nRot) then outputChatBox("vZ: " .. vecZ .. ", normZ: " .. normZ) end end addEventHandler("onClientVehicleCollision", getRootElement(), checkLanding) wasOnGround is isVehicleOnGround of the previous frame. i thought that normZ is up vector of collision, but now i see
5. ## 4 wheel landing

I haven't learned matrices in school yet so i'm not sure how they work (all i know about them, is that they are table of numbers). Could anyone show me how you get the up vector of the vehicle and the up vector of the surface of collision (onClientVehicleCollision).
6. ## 4 wheel landing

Well the easiest way is still pretty hard! I'll try as soon as I'll be able to.
7. ## 4 wheel landing

Hello all! I haven't post for a very long time now mostly because i am using wiki . Does anyone know how to detect that vehicle landed on 4 wheels (not 0 XY rotation, but 0 XY rotation relative to the element that player landed on)? i have no clue how to even find element that vehicle landed on... please help!
8. ## is it possible...

I have!! but don't know how to fix it!

not working!
10. ## is it possible...

ok i figured it out! But i need to know how to calculate where is 1 unit infront of ped! And i have no idea how! help?!!
11. ## help fix bug!

Hi! I must fix bug at map editor! look at this video to see what happens. you don't have to make comment if u know how to fix. You can make post here!!!
12. ## is it possible...

help with working script!
13. ## is it possible...

it can be deleted by anyone!
14. ## is it possible...

no! It can't!
15. ## is it possible...

ok! This is what i have: botPed = null function createBot() if (botPed == null ) then botPed = createPed( 312, 1989, -2190, 14, 180, 0, 180 ) outputConsole("Bot is in game!") else outputConsole("Bot already exists.") end end function deleteBot() if (botPed ~= null) then destroyElement( botPed ) outputConsole("Bot has been deleted.") botPed = null else outputConsole("No bot to remove.") end end function smartBotON() setPedAnimation( botPed, "ped", "run_player" ) -- detection event addEventHandler( "onClientR
×

• #### MTA Network

×
• Create New...