-
Posts
2,608 -
Joined
-
Last visited
Everything posted by 12p
-
Your TXD is probably invalid (uncompatible).
-
I will answer you via PM, ok?
-
Step 1: http://ajaxtrans.com/index.es.php Step 2: What is the error?
-
Don't bump!!! God, that's not very clever from you, Maurize! That will obviously don't work! getPointFromDistanceRotation returns a 2D POSITION. function getPointFromDistanceRotation( x, y, dist, angle ) local a = math.rad( 90 - angle ) local dx = math.cos( a ) * dist local dy = math.sin( a ) * dist return x + dx, y + dy end addEvent( "beiPower", true ) addEventHandler( "beiPower", getRootElement(), function() local px, py, pz = getElementPosition( source ) local rx, ry, rz = getElementRotation( source ) local veh = createVehicle( 542, px, py, pz ) attachElements( veh, source, 0, 0, 1.5, rx, ry, rz ) bindKey( source, "mouse1", "down", function( player ) local px, py, pz = getElementPosition( player ) local rx, ry, rz = getElementRotation( player ) local nx, ny = getPointFromDistanceRotation( px, py, 1, rz ) unbindKey( player, "mouse1", "down", source ) setPedAnimation( player, "RYDER", "Van_Throw", 2000, false, false, false, false ) detachElements( veh, player ) setElementRotation( veh, 0, 0, pz ) setElementVelocity( veh, (nx - px)/10, (ny - py)/10, 0 ) --This determines the direction of the movement. You can increase or reduce the division "/10". end ) end )
-
onZoneEnter may be applied to GTA SA built-in zones like Idlewood? Then, yeah, it would be good. isPlayerLoggedIn can be done via scripting, here you have: function isPlayerLoggedIn ( player ) if getElementType ( player ) ~= "player" then return end return not isGuestAccount ( getPlayerAccount ( player ) ) end
-
Maybe it can be done via scripting. Almost everything can be done via scripting.
-
There is a simple way to make this without using SQL and many accounts at the time. Create an account called "root" or something. There, you must set it's account data to a JSON-compiled table. In the table, you add the values you need. That's it
-
function greenzoneEnter ( element, matchingDimension ) local t = getElementType( element ) if t == "player" then outputChatBox ( "* You Entered The Safezone!", element, 50, 252, 3 ) elseif t == "ped" then killPed ( element ) end addEventHandler ( "onColShapeHit", greenzone, greenzoneEnter )
-
You can use https://wiki.multitheftauto.com/wiki/Get ... ceRotation And basic math to do that.
-
*Removed
-
CapY, there's no need to show the script. Be more specific! Do you want the car to fly exactly in front of itself?
-
I had this idea a long time before. But didn't know how to make it possible. Good job ^^
-
I would suggest function commitSuicide ( cmd ) if cmd == "kill" then -- kill the player and make him responsible for it killPed ( source, source ) -- shows the kill msg outputChatBox ( getPlayerName ( source ) .. " killed himself.", getRootElement(), 255, 255, 255, true ) end end -- attach our handler to the "kill" command addEventHandler ( "onPlayerCommand", getRootElement ( ), commitSuicide ) Try it.
-
What the... You first spoke about onClientPlayerDamage, then about onPlayerDamage. For me it doesn't make much sense... Nvm.
-
It did at MTA 1.0.4. The effect cancel of setElementHealth made my player to be kicked out due to AntiCheat #1 So I say "IT SHOULD WORK WITH setElementHealth". Cannot try zombies resource atm, I'll do later (in about 11 hours )
-
onPlayerDamage cannot be cancelled. You edited wrong lol (or maybe you used onPlayerDamage at runcode and failed?)
-
"runcode" works client-side too? Didn't know it, damnit.
-
Yes it does. Tested with "zombies" resource (do you remember I told you a long time ago about "AC#1" kicking me when a zombie was punching me? It was cancelEvent() applied to onClientPlayerDamage )
-
onClientPlayerDamage ==> cancelEvent
-
I'm not the most technichian. Can you just tell me this: WHAT GENERATION IS IT? 2007? Btw I use WinXP Well... I cannot buy anything now (only the processor and the RAM). But I need to be sure about what I want, so I don't buy something that will not work with my espectations.
-
This is related to topic: When using setElementHealth, is onClientPlayerDamage triggered?
-
No, estoy ocupado.
