-
Posts
1,248 -
Joined
-
Last visited
Everything posted by WhoAmI
-
Well I can't see an error, maybe someone with more experience would help you.
-
Everything looks fine, hmm. Any errors? Put outputChatBox after loadstring to check if script gets there.
-
outputConsole(DrawString) Does it output correct stuff?
-
loadstring doesn't work because you put it after 'return'.
-
dbExec ( getElementData ( resourceRoot, "dayz:resource.settings.database" ), "INSERT INTO `players` (`serial`,`password`,`data`) VALUES (?,?,?)", "serial", "password", "3,4" ) For checking what is in database, I prefer: https://addons.mozilla.org/pl/firefox/a ... e-manager/
-
I only found this https://wiki.multitheftauto.com/wiki/DxDrawGifImage Or create image with long width and just change the X position.
-
Maybe you have to user moveObject
-
--SERVER function makeitburn ( player, commandName, fdfire ) triggerClientEvent( "createfdfire", player, fdfire ) end addCommandHandler ( "fdfire", makeitburn ) --CLIENT function fdfire ( fireid ) if fireid then if tonumber(fireid) == 1 then createFire(1700, -1168, 23, 60) createFire(1698, -1168, 23, 60) local blipicon = createBlip( 1700, -1168, 23, 43, 0, 0, 0, 255 ) outputChatBox("Fire created at 1700, -1168, 23") local onlinePlayers = getElementsByType("player") for index, player in pairs(onlinePlayers) do local x, y, z = getElementPosition(player) local distance = getDistanceBetweenPoints3D(1725, -1130, 24, x, y, z) if (distance <50) then setTimer(function () destroyElement(blipicon) end, 900000, 1) setTimer(function () triggerEvent("ringTheBell", player) end, 5000, 1) end end elseif tonumber(fireid) == 2 then createFire(1729, -1174, 23, 60) createFire(1727, -1174, 23, 60) local blipicon = createBlip( 1729, -1174, 23, 43, 0, 0, 0, 255 ) outputChatBox("Fire created at 1729, -1174, 23") local onlinePlayers = getElementsByType("player") for index, player in pairs(onlinePlayers) do local x, y, z = getElementPosition(player) local distance = getDistanceBetweenPoints3D(1725, -1130, 24, x, y, z) if (distance <50) then setTimer(function () destroyElement(blipicon) end, 900000, 1) setTimer(function () triggerEvent("ringTheBell", player) end, 5000, 1) end end else outputChatBox("Missing ID") end else outputChatBox("Syntax: /fdfire [id]", thePlayer) outputChatBox("IDs available: 1, 2", thePlayer) end end -- addCommandHandler("fdfire", fdfire) addEvent ( "createfdfire", true ) addEventHandler ( "createfdfire", root, fdfire )
-
Check this out addEventHandler ( "onClientPlayerChoke", localPlayer, function ( weapon ) if ( source ~= localPlayer ) then return end if ( weapon == 41 ) then cancelEvent() end end )
-
Next time be more specific when you are creating the topic. I wasn't sure what are you talking about. Anyway, You're welcome.
-
I'm not sure if it will works, but addEventHandler ( "onPlayerCommand", root, function ( command ) if ( command == "login" or command == "register" ) then cancelEvent ( ) end end ) @UP was faster.
-
function makeitburn (player, commandName, fdfire) triggerClientEvent( "createfdfire", player, fdfire ) end addCommandHandler ( "fdfire", makeitburn ) /fdfire something If doesn't work show us clientside.
-
addEventHandler ( "onPlayerChat", root, function ( message, messageType ) if ( messageType == 2 ) then cancelEvent ( ) local name = getPlayerName ( source ) local team = getPlayerTeam ( source ) for _, player in ipairs ( getElementsByType ( "player" ) ) do if ( getPlayerTeam ( player ) == team ) then outputChatBox ( name .. "#FFFFFF: " .. message, player, 255, 255, 255, true ) end end end end ) Check this out ( serverside script ).
-
But what bug? USE BRAIN. Any errors? Don't act like stupid.
-
onPlayerTarget event is way better.
-
getPedTarget destroyElement
-
Lol, man. What bug? Any errors in debug?
-
Just delete takeAllWeapons ( source ) from onPlayerWasted event.
-
You're welcome.
-
You're welcome. But I got no idea for what are you doing this?
-
You're welcome, cheers from Poland.
-
Try this setPlayerTeam ( source, getTeamFromName ( "VIP" ) )
-
accountData = setAccountData accountData ( account, string, value )
-
Don't use timer, use event onElementDataChange instead. If someone get kill you are setting the data, so the event would be triggered.
