-
Posts
378 -
Joined
-
Last visited
Everything posted by Sparrow
-
إنها لا تعمل local vehicles = {} function spawnVeh(model) local x, y, z = getElementPosition(source) local rot = getPedRotation(source) local theVehicle = createVehicle (model, x, y, z, 0, 0, rot) if isElement(vehicles[source]) then destroyElement(vehicles[source]) end warpPedIntoVehicle(source,theVehicle) end addEvent("onGUIClick",true) addEventHandler("onGUIClick",root,spawnVeh)
-
شكرا JR10. كيف أضع فقط يستطيع اللاعب أن يقوم بإنتاج سيارة واحدة, و إذا كانت له سيارة نضيع الأولى و ينتج أخرى
-
إنها لا تدمر مركبة function destroyVeh() local theVehicle = getPedOccupiedVehicle (localPlayer) if (theVehicle) then destroyElement (theVehicle) outputChatBox("Your vehicle has been destroyed.", 0, 255, 0) guiSetVisible(window, false) showCursor(false) else outputChatBox("You aren't in a vehicle.", 255, 0, 0) guiSetVisible(window, false) showCursor(false) end end addEventHandler("onClientGUIClick", destroyButton, destroyVeh, false)
-
fix is working, only the destroy didn't work, it didn't destroy the vehicle.
-
ok, thanks solidsnake, EDIT: the vehicle didn't destroyed when I press "Destroy" button.
-
I've done a window with grid list and buttons to spawn/destroy and fix the vehicle. spawn is working as well, but fix and destroy didn't work, also no errors on debugscript 3. script: function destroyVeh(thePlayer) if (thePlayer) then local theVehicle = getPedOccupiedVehicle (thePlayer) if (theVehicle) then destroyElement (theVehicle) outputChatBox("Your vehicle has been destroyed.", thePlayer, 0, 255, 0) else outputChatBox("Access Denied.", thePlayer, 255, 0, 0) end end end addEventHandler("onClientGUIClick", destroyButton, destroyVeh, false) function fixVeh(thePlayer) if (thePlayer) then local theVehicle = getPedOccupiedVehicle (thePlayer) if (theVehicle) then fixVehicle (theVehicle) outputChatBox("Your vehicle has been fixed.", thePlayer, 0, 255, 0) else outputChatBox("Access Denied.", thePlayer, 255, 0, 0) end end end addEventHandler("onClientGUIClick", fixButton, fixVeh, false)
-
lol, bad local server thank you anyways for help
-
still didn't work for me
-
didn't work http://img853.imageshack.us/img853/9899 ... 215229.png
-
ok, I'll try. EDIT: I test it with others X, Y and Z coordination, nothing happend, gate didn't work.
-
does it work for you? it didn't for me
-
still not working, also no errors on debugscript 3 and on mtaserver.exe
-
I'm trying to set a gate for LSPD that opens for whogot polices skins, the problem is the gate didn't move. he is the script: local policeSkins = { [280]=true, [281]=true, [282]=true, [283]=true, [284]=true, [285]=true, [286]=true } local theMarker = createMarker (1545.400, -1627.600, 13.400, "cylinder", 6, 255, 255, 255, 0) local gate = createObject (968, 1544.6999511719, -1631, 13.199999809265, 0, 270, 270) function openGate(thePlayer) if policeSkins[getElementModel (thePlayer)] then moveObject (gate, 1500, 1544.700, -1630.800, 13.300) end end addEventHandler("onMarkerHit", theMarker, openGate) function closeGate(thePlayer) if policeSkins[getElementModel (thePlayer)] then moveObject (gate, 1500, 1544.6999511719, -1631, 13.199999809265) end end addEventHandler( "onMarkerLeave", theMarker, closeGate)
-
2r1
-
if faut que ton serveur est fermer lorsque tu change le ACL.
-
ouvre ton MTA folder>Server>Mods>Deathmatch>mtaserver. apres, ajouter à la fin de la page: c'est tous
-
ابي اتعلم (العلم نور والجهل ظلام) شباب تكفون ادخلو
Sparrow replied to faisl2002's topic in Arabic / العربية
قم بالعمل، وسوف نقوم باصلاح أخطاءك -
thanks kevin for this information
-
lolol, scripting TUTs on arabic, gr8. teamAdmin = createTeam ( "Admin", 255, 0, 0 ) function addtoteam(player) if ( isObjectInACLGroup ( "user." ..getAccountName(getPlayerAccount(player)) , aclGetGroup ( "Admin" ) ) or isObjectInACLGroup ( "user." ..getAccountName(getPlayerAccount(player)) , aclGetGroup ( "SuperModerator" ) ) or isObjectInACLGroup ( "user." ..getAccountName(getPlayerAccount(player)) , aclGetGroup ( "Moderator" ) )) then setPedSkin ( player, 116 ) giveWeapon ( player, 22, 500, true ) giveWeapon ( player, 30, 500, true ) setPedArmor ( player, 100 ) setElementHealth (player, 100) setPlayerTeam ( player, teamAdmin ) else outputChatBox("YOU MOVED TO TEAM ADMIN", player, 255, 0, 0) end end addCommandHandler("admins", addtoteam) function addtoteamtimer() setTimer(addtoteam,3000,1,source) end addEventHandler("onPlayerLogin",getRootElement(),addtoteamtimer)