
Prat
Members-
Posts
32 -
Joined
-
Last visited
Everything posted by Prat
-
because of .map file its written dimension = "0"
-
How to build a map in dimension 5 ? Thank you.
-
now it works successfuly , the setPlayerMuted is infinite , i want to time it to 10 seconds. and thanks castillo <3
-
i'v used this but it ouput a bad arg line in debug msg addEvent ("onMuteNab", true) addEventHandler ("onMuteNab", root, function () victim = getPlayerFromName(playerName) setPlayerMuted (victim, true) outputChatBox ("You have been Muted", victim) end )
-
i hate the "getPlayerBlablabla" thingy dingy obama tingy, so please add it for me , i'm so confused now
-
would you add it please? :3 here is the server side :- addEvent ("onMutePlaya") addEventHandler ("onMutePlaya", root, function () setPlayerMuted (playerName, true) end ) Also i wannna change "setPlayerMuted" to 10 minutes instead of infinite. Appreciate that man EDIT: localPlayer is the muter or the muted guy ?
-
exactly , how to send it to the remote trigger?
-
Now i hope it works. Good luck function spawnGood ( player ) spawnPlayer ( player, posX, posY, posZ - 9, 0, 111, 0, 0, nil ) giveWeapon ( player, 23, 100 ) giveWeapon ( player, 8, 1 ) giveWeapon ( player, 35, 1 ) end function wastedGood ( ) spawnPlayer ( source, posX, posY, posZ - 9, 0, 121, 0, 0, nil ) giveWeapon ( source, 23, 100 ) giveWeapon ( source, 8, 1 ) giveWeapon ( source, 35, 1 ) end function spawnDead ( player ) spawnPlayer ( player, posX, posY, posZ - 9, 0, 111, 0, 0, nil ) giveWeapon ( player, 23, 100 ) giveWeapon ( player, 8, 1 ) giveWeapon ( player, 35, 1 ) end function wastedDead ( ) spawnPlayer ( source, posX, posY, posZ - 9, 0, 121, 0, 0, nil ) giveWeapon ( source, 23, 100 ) giveWeapon ( source, 8, 1 ) giveWeapon ( source, 35, 1 ) end addEventHandler ( "onPlayerJoin", getRootElement (), function ( ) bindKey ( "1", "down", spawnGood ) bindKey ( "2", "down", spawnDead ) end ) addEventHandler ( "onResourceStart", resourceRoot, function ( ) for _, player in ipairs ( getElementsByType ( "player" ) ) do bindKey ( "1", "down", spawnGood ) bindKey ( "2", "down", spawnDead ) end end ) addEventHandler ( "onPlayerWasted", getRootElement (), wastedGood ) addEventHandler ( "onPlayerWasted", getRootElement (), wastedDead )
-
Hi there , i'v fixed it so now it gonna create 2 object randomly from #locations once the resource starts. replace ID in line 12 & 13 with the object model id , you can find it in map editor. i believe this code is easier than denny's. Good Luck locations = { { 529, -1884, 3 }, { 612, -1884, 3 }, { -2920, 68, 1 }, { -2913, 159, 3 }, } function startDaTable () random = math.random(#locations) x, y, z = locations[random][1], pickupT[random][2], pickupT[random][3] createObject ( ID, x, y, z) createObject ( ID, x, y, z) end addEventHandler ("onResourceStart", root, startDaTable)
-
i believe there is no reason to stop it from working. Good luck local gate = createObject(976,-1534.7,482,6.32, 0, 0, 0 ) function opengatep() if not ( getPlayerTeam( thePlayer ) ) == false then if ( getTeamName( getPlayerTeam( thePlayer ) ) == "myTeam" ) then moveObject(gate, 2000, -1544,482,6.32, 0, 0, 0 ) end end end function closegatep() if not ( getPlayerTeam( thePlayer ) ) == false then if ( getTeamName( getPlayerTeam( thePlayer ) ) == "myTeam" ) then moveObject(gate, 2000, -1534.7,482,6.32, 0, 0, 0 ) end end end cancello = createMarker ( -1530, 482.2, 6.2 ,"cylinder", 13, 0, 0, 255, 0) addEventHandler("onMarkerHit", cancello, opengatep) addEventHandler("onMarkerLeave", cancello, closegatep)
-
Why does Windows 8 Smart Screen stops me from launch it ? i'm not quite sure it doesn has virus
-
Hallo playas today i suggested to make a an admin panel , just to test my skills, but i'm stuck on something , i searched over the wiki , but nothing. the script is an admin panel ; gridlist on the left gets the online players , and search field intop of it. when you select the column of the player name , you can make the actions (there is buttons for actions on the gui), problem is , guiGridListGetItemText is client sided only , and i want the server side to do the actions to the player , here is the gui : GUIEditor = { edit = {}, button = {}, window = {}, label = {}, gridlist = {} } GUIEditor.window[1] = guiCreateWindow(458, 120, 370, 459, "Helpers Panel", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.edit[1] = guiCreateEdit(20, 84, 102, 23, "", false, GUIEditor.window[1]) GUIEditor.gridlist[1] = guiCreateGridList(10, 112, 128, 329, false, GUIEditor.window[1]) GUIEditor.label[1] = guiCreateLabel(20, 55, 152, 24, "Players Search", false, GUIEditor.window[1]) guiSetFont(GUIEditor.label[1], "default-bold-small") guiLabelSetColor(GUIEditor.label[1], 51, 115, 203) GUIEditor.button[1] = guiCreateButton(266, 190, 94, 47, "Mute Player", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[1], "default-bold-small") guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FF3373CB") GUIEditor.button[2] = guiCreateButton(265, 254, 95, 47, "Unmute Player", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[2], "default-bold-small") guiSetProperty(GUIEditor.button[2], "NormalTextColour", "FF3373CB") GUIEditor.label[2] = guiCreateLabel(148, 24, 218, 103, "NOTE: While punishing players , it\n would be recommended to\n include screen shots to proof in\n case the helper got complainted\n to a Staff.", false, GUIEditor.window[1]) GUIEditor.button[3] = guiCreateButton(267, 326, 93, 47, "Kick Player", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[3], "default-bold-small") guiSetProperty(GUIEditor.button[3], "NormalTextColour", "FF3373CB") GUIEditor.button[4] = guiCreateButton(267, 394, 93, 47, "Freeze", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[4], "default-bold-small") guiSetProperty(GUIEditor.button[4], "NormalTextColour", "FF3373CB") GUIEditor.button[5] = guiCreateButton(148, 394, 93, 47, "Unfreeze", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[5], "default-bold-small") guiSetProperty(GUIEditor.button[5], "NormalTextColour", "FF3373CB") GUIEditor.button[6] = guiCreateButton(148, 326, 93, 47, "Warp", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[6], "default-bold-small") guiSetProperty(GUIEditor.button[6], "NormalTextColour", "FF3373CB") GUIEditor.button[7] = guiCreateButton(146, 254, 95, 47, "Kill Player", false, GUIEditor.window[1]) guiSetFont(GUIEditor.button[7], "default-bold-small") guiSetProperty(GUIEditor.button[7], "NormalTextColour", "FF3373CB") function showGui ( thePlayer) if not guiGetVisible(GUIEditor.window[1]) then guiSetVisible(GUIEditor.window[1], true) showCursor(true) else guiSetVisible(GUIEditor.window[1], false) showCursor(false) end end addCommandHandler ("panil", showGui) local playerList = guiCreateGridList(10, 112, 128, 329, false, GUIEditor.window[1]) -- Create the grid list local column = guiGridListAddColumn( playerList, "Player", 0.85 ) -- Create a 'players' column in the list if ( column ) then -- If the column was successfully created for id, playeritem in ipairs(getElementsByType("player")) do local row = guiGridListAddRow ( playerList ) guiGridListSetItemText ( playerList, row, column, getPlayerName ( playeritem ), false, false ) end end function mutePlayer ( thePlayer) local playerName = guiGridListGetItemText ( playerList, guiGridListGetSelectedItem ( playerList ), 1 ) triggerServerEevent ("onMutePlaya", root) end addEventHandler("onClientGUIClick", GUIEditor_Button[1] , mutePlayer) Also, server side "setPlayerMuted" it does mute the player for infinite , and i want it to be 10 minutes. Cheers , hope you guys answer me
-
oh shit , timer is not working Edit: oh shit nvm i pasted the wrong code , Lol
-
YOU ARE A ONE PIECE HELL OF COOL GUY , CHEEEEEEERS
-
aaand one more thing please , after hiting the deliver marker , i want to set a timer so you don't have to do /startshift again. so once you deliver it , another destination displays automaticaly
-
Appreciate castillo , but anyone can make /staftshift multiple times and it spawns infinite markers and blips on the map , thus this is abusable, can you fix it please?
-
tried everything , not working. no debug message.
-
thanks but that doesn't really matter , just for the function 2 is not working
-
Hello after wasting a lot of my time , i made a script but itsn't working. so basically the script is about Pilot job , when you do /startshift , a blip and marker displays on ur map , so its working perfectly so far , but the problem is , when i add markerhit event in other function it doesn't work , so i need ur help here. the script should work in these ways :- only "Pilot" team can do /startshift you will only get money when you hit the marker by the vehicle "Dodo". local deliverP = { --Los Santos {1787.7626953125, -2555.7822265625, 13}, {-1662.8570556641, -291.42846679688, 14}, {1448.5712890625, 1508.5714111328, 10}, } thisRes = getResourceRootElement(getThisResource()) local PilotPlane = createVehicle (593, 1890.3594970703, -2493.8330078125, 13.53911781311) function PilotDeliver() random = math.random(#deliverP) x, y, z = deliverP[random][1], deliverP[random][2], deliverP[random][3] delBlip = createBlip ( x,y,z, 51) delmarker = createMarker ( x,y,z, "cylinder", 5, 255, 160, 0, 100) outputChatBox ( "You have a new flight , go to location bliped on your map!", root, 255, 100, 0, true ) end addCommandHandler ("startshift", PilotDeliver) function DelPayment(hitElement) if getElementType(hitElement) == "player" and (hitElement == localPlayer) then randomPay = math.random ( 2000, 5000 ) givePlayerMoney (randomPay) outputChatBox ( "You Arrived to your distenation , This is your payment"..tostring(randomPay).."$", root, 255, 100, 0, true ) end end addEventHandler ("onMarkerHit", delmarker, DelPayment) thanks for reading. cheers