-
Posts
1,312 -
Joined
-
Last visited
Everything posted by KariiiM
-
It must be in server side local Team = createTeam("Criminal", 255, 0, 0) addCommandHandler("Criminal", function (player) setPlayerTeam (player,getTeamFromName("Criminal")) end)
-
Nice one
-
Put piece of your code your problem is in client side
-
function crosshair () local vehicle = getPedOccupiedVehicle ( thePlayer ) if vehicle == 520 then
-
Your error is about getPedOccupiedVehicle ,if this didnt works inform me to edit my post function crosshair () if getPedOccupiedVehicle(localPlayer) then if getElementModel(getPedOccupiedVehicle(localPlayer)) == 520 true then --there local veh = getPedOccupiedVehicle(gMe) --there local col2 = getElementData(veh, "r.col2") --there local col1 = getElementData(veh, "r.col1") if not(col2) or not(col1) then return end local x, y, z = getElementPosition(col2) local x1, y1, z1 = getElementPosition(col1) z1 = z1+getElementDistanceFromCentreOfMassToBaseOfModel(veh)*2 local hit, x2, y2, z2 = processLineOfSight(x, y, z, x1, y1, z1) if not(x2) or not(y2) or not(z2) then x2, y2, z2 = x, y, z end local sx, sy = getScreenFromWorldPosition(x2, y2, z2) if not(sx) or not(sy) then return end dxDrawLine(sx, sy-12.9, sx, sy+12.9, tocolor(0, 255, 0), 2) dxDrawLine(sx-12.9, sy, sx+12.9, sy, tocolor(0, 255, 0), 2) end end end addEventHandler("onClientRender", root, crosshair)
-
Ah sorry i didnt take attention try this function crosshair () if getPedOccupiedVehicle(localPlayer) then if getElementModel(getPedOccupiedVehicle(localPlayer)) == 520 then local col2 = getElementData(veh, "r.col2") local col1 = getElementData(veh, "r.col1") if not(col2) or not(col1) then return end local x, y, z = getElementPosition(col2) local x1, y1, z1 = getElementPosition(col1) z1 = z1+getElementDistanceFromCentreOfMassToBaseOfModel(veh)*2 local hit, x2, y2, z2 = processLineOfSight(x, y, z, x1, y1, z1) if not(x2) or not(y2) or not(z2) then x2, y2, z2 = x, y, z end local sx, sy = getScreenFromWorldPosition(x2, y2, z2) if not(sx) or not(sy) then return end dxDrawLine(sx, sy-12.9, sx, sy+12.9, tocolor(0, 255, 0), 2) dxDrawLine(sx-12.9, sy, sx+12.9, sy, tocolor(0, 255, 0), 2) end end end addEventHandler("onClientRender", root, crosshair)
-
You want these direct x lines show in the screen when you press a "button"? You didnt explain well what you wanted to do,so it will be easy to help after understanding your point.
-
If you didn't understand what the don said,i will try to be clear with you, To give the accountaccess you've to add your script name (filename) to Acl.xml ,so where exactly? thats what i will show you Open your your ACL.xml and add the line under the admin section: "resource.fillename"> Or you can do it in game if you want, go to your ACL on the admin panel and add object to the admin section and call it resource.fillename
-
3lina w 3alik
-
Yes,as tomas said its not a good way to get players,there's alot of ways to advertise your server out of MTA ,by recording a video and sharing it in youtube also facebook / skype Good luck
-
try this local lp = getLocalPlayer() addEventHandler("onClientRender", root, function() if getElementModel lp == 0 true then dxDrawRectangle(0, 0, 1680, 1050, tocolor(0, 0, 0, 255), false) dxDrawText("Please Wait 10 Seconds", 445 + 1, 459 + 1, 1186 + 1, 596 + 1, tocolor(0, 0, 0, 255), 3.00, "bankgothic", "center", "top", true, false, false, true, false) dxDrawText("Please Wait 10 Seconds", 445, 459, 1186, 596, tocolor(254, 255, 254, 255), 3.00, "bankgothic", "center", "top", true, false, false, true, false) end end )
-
Dude,just be honest and don't hide the credit
-
To be honest,me too i didn't understand anything of what you're trying to do,Edit what you said in the first and explain well to let everyone understand.
-
You can finds them there just search
-
Which one? and its not an full code Put your code and we'll helps we have no idea about your Police and Criminal team names.
-
-- Functions dxCreateShader() dxCreateTexture() getControlState() dxSetShaderValue() engineApplyShaderToWorldTexture() -- Events onClientRender()
-
Here i scripted a code about what you're wanted for it's server side so add a meta like that Server.lua (Server side) local GreenZone = createColRectangle ( ) --Put your Greenzone pos plus Size of it. Example:(x,z,255,130) local Radar = createRadarArea () -- Put greenzone (pos plus Size,Color of Zone,Alpha) function zoneEnter ( thePlayer, matchingDimension ) if matchingDimension and isElement(thePlayer) and getElementType(thePlayer) == "player" then triggerClientEvent(thePlayer, "zoneEnter", thePlayer) getPedWeapon(localPlayer) == 11 then getPedWeapon(localPlayer) == 14 then toggleControl ( thePlayer, "fire", false ) toggleControl ( thePlayer, "next_weapon", false ) toggleControl ( thePlayer, "previous_weapon", false ) outputChatBox( "You've entered to the greenzone,you can use only Dildo and Flowers.",thePlayer, 255,0,0) end end addEventHandler ( "onColShapeHit", GreenZone, zoneEnter ) function zoneExit ( thePlayer, matchingDimension ) if matchingDimension and isElement(thePlayer) and getElementType(thePlayer) == "player" then triggerClientEvent(thePlayer, "zoneExit", thePlayer) toggleControl ( thePlayer, "fire", true ) toggleControl ( thePlayer, "next_weapon", true ) toggleControl ( thePlayer, "previous_weapon", true ) outputChatBox ( "You've left the greenzone,now all your ammos will works.",thePlayer,255,0,0) end end addEventHandler ( "onColShapeLeave", GreenZone,zoneExit )
-
Show us the debugscript 3 errors
-
Hello there,i didn't understand your system well Do you mean,if a player entered the GreenZone his ammo will be not working but the "dildo" ,"Flowers" ammo will works?
-
Hey mates I'll like to share with you my personal works,so it's an map of "Jail interior" with an jail system script,i like to hear your opinions about that because it took alot of time to be done It's the "Version 1.0" the second version will be more developments than this one & with PD interior. Jail Interior v1.0: http://i.imgur.com/adDQIU4.jpg http://i.imgur.com/PNP77RY.jpg http://i.imgur.com/4lqLE7S.jpg http://i.imgur.com/ZSnxpfw.jpg http://i.imgur.com/ZOAHo1l.jpg http://i.imgur.com/H6uifrh.jpg
-
You've to base your script to Mysql database so it will automaticly save your car lists and owners when they loggout, and just update it in the database. Install LAMP,XAMPP, Apache and MySQL come installed with it. If you didn't know how to do that, search on forums for some tutorials about how to use XAMPP.
-
Try this by putting it in your Police part local team = getPlayerTeam() local theTeamName = getTeamName(team) if ( theTeamName == "Police" ) and (target) and getPlayerWantedLevel ( source ) > 0 ) then return end