-
Posts
7,337 -
Joined
-
Days Won
11
Everything posted by TAPL
-
setVehicleRespawnPosition
-
oh, i don't see where is the event onPlayerLogin in your code.
-
Change line 21 to: addEventHandler ( "onPlayerQuit", getRootElement ( ), function() saveAccountData(source) end)
-
هو قصده معدل على الصيغه بعد التشفير اكيد طبعا اذا غيرت الصيغه بعد التشفير مثلا من luac الى lua بينعطب الملف
-
You see this? for player,i in pairs(getElementsByType("player")) do It should be: for i,player in pairs(getElementsByType("player")) do
-
-
Huh? you kidding me? Did you even start the resource? Post your meta or upload your resource at: http://mediafire.com
-
Huh? this is the same, i only change p to killer and added a check. Let me know what this code output. Client Side: function statsup(killer) outputChatBox("Client Test: 1") if killer and killer == localPlayer and getElementData(source, "filmbot") then outputChatBox("Client Test: 2") triggerServerEvent("stats", killer) end end addEventHandler("onClientPedWasted", root, statsup) Server Side: function makeitgoup() outputChatBox("Server Test: 1") local statx = getPedStat(source, 63) if (statx > 2)then outputChatBox("Server Test: 2") triggerEvent("statsup22", source) setPedStat(source, 63, 0) outputChatBox("Server Test: 3") else outputChatBox("Server Test: 4") setPedStat(source, 63, statx + 1) end outputChatBox("Server Test: 5") end addEvent("stats", true) addEventHandler("stats", root, makeitgoup)
-
function testPed() ..... if ( isPedDead ( shopKeeper ) ) then triggerClientEvent (source, "testMessage1", root) testMarker = createMarker(-27,-91.6, 1002.5, 'cylinder', 1.5, 0, 100, 255, 255) addEventHandler( "onMarkerHit", testMarker, testHit ) setElementInterior (robMarker, 18) end end function testHit ( thePlayer, matchingDimension ) local elementType = getElementType( thePlayer ) if (elementType) then triggerClientEvent (source, "testMessage2", root) end end
-
Not my client-side, but your element data. getElementData(source, "filmbot") Where did you set the element data?
-
Was your stat bigger than 2?
-
https://forum.multitheftauto.com/viewtopic.php?f=91&t=48495
-
There no function to respawn the ped, you will need to create the ped again. You can use this event: onPedWasted.
-
Change this: if getElementType(target) == "ped" and target == testPed then To: if target and getElementType(target) == "ped" and target == testPed then And Change this: giveWeapon(target, 31, 100) To: giveWeapon(target, 31, 100, true)
-
Try this (Not tested). --server testPed = createPed(skin, x, y, z) function testAttack(target) if getElementType(target) == "ped" and target == testPed then giveWeapon(target, 31, 100) triggerClientEvent(root, "testShoot", source, target) end end addEventHandler("onPlayerTarget", root, testAttack) --client function testShoot(target) local x, y, z = getElementPosition(source) setPedAimTarget(target, x, y, z) setPedControlState(target, "fire", true) end addEvent("testShoot", true) addEventHandler("testShoot", root, testShoot)
-
The size of exitMarker is too small, try increase the size.
-
createRadarArea createColRectangle getElementType toggleControl isElementWithinColShape cancelEvent Event: "onColShapeHit" Event: "onColShapeLeave" Event: "onClientPlayerDamage"
-
luac او lua ايضاً الملف مو لازم يكون آخره تقدر تحط اي شي
-
function statsup(killer) if killer and killer == localPlayer and getElementData(source, "filmbot") then triggerServerEvent("stats", killer) end end addEventHandler("onClientPedWasted", root, statsup) function makeitgoup() local statx = getPedStat(source, 63) if (statx > 2)then triggerEvent("statsup22", source) setPedStat(source, 63, 0) else setPedStat(source, 63, statx + 1) end end addEvent("stats", true) addEventHandler("stats", root, makeitgoup) If it doesn't work, post the function that attached to the event "statsup22" and explain what is doesn't work.
-
Line 10 and 12 the color code should go after " not before (same as line 29). Line 21 use source not team and remove team from line 20 (empty).
