-
Posts
1,134 -
Joined
-
Last visited
-
Days Won
37
Everything posted by NeXuS™
-
I think you could use some nicer things tho. Maybe create some objects, attach them together (so you can move them easily, with moveObject). You'll have to set up some positions early on, or you could just get a random player call a function near to him to get the ground's height. (If you want to do it this way, feel free to ask here, I'll help about it.) Back to the easy part. Creating an object and moving it on server side is easy. After that, you could use a marker, or a nicer way would be onElementClicked on client side. Again, feel free to choose, and respond here, so we can help about it.
-
Honnan tudod, hogy nem nő a fat statisztikája a pednek?
- 2 replies
-
- trigger server event
- setpedstat
-
(and 4 more)
Tagged with:
-
Nvm, it's one client sided, and one server sided script. Didnt check if it was or not. Try triggering without any args. Or maybe check debugscript?
-
Do you load the server sided script first in your meta.xml?
-
addEventHandler("onClientPlayerWeaponFire", getRootElement(), function ( weapon, ammo, ammoInClip ) outputChatBox(weapon) local x,y,z = getElementPosition(source) if weapon == 1834 then local sound = playSound3D("sounds/AK74.wav", x,y,z) setSoundVolume(sound,10) setSoundMaxDistance(sound,75) end end)
-
You should read the dbPoll and dbFree desc.
-
local sqlConnect = dbConnect("sqlite", "test.db") local querryH = dbQuerry(sqlConnect, "SELECT * FROM accounts") if querryH == statementHere then neededData = dbPoll(querryH, -1) else dbFree(querryH) end Thats all.
-
dbQuery is for getting data, dbExec for inserting.
-
local hitMarker = createMarker (1638.0502929688, -1152.9975585938, 22.5, "cylinder", 4, 255, 0, 0, 100) function enterFunction(hitPlayer, matchingDimension) if getElementType(hitPlayer) == "player" and not isPedInVehicle(hitPlayer) then setElementPosition(hitPlayer, 1637.2869873047, -1132.6866455078, 23.90625) outputChatBox("Welcome to Los Santos Boss Area!", hitPlayer) end end addEventHandler( "onMarkerHit", hitMarker, enterFunction)
-
Refresh the page, I edited the post above.
-
It's because its not a set value. You are multipling your values with x and y.
-
Whats wrong with it? They are bigger.
-
Then copy the addNotification's server side too.
- 15 replies
-
- notif
- notifacition
- (and 6 more)
-
Is this client side or server side?
- 15 replies
-
- notif
- notifacition
- (and 6 more)
-
Are ya in the Admin ACL group? *EDIT* Just found out that a bracket was missing. addEventHandler("onPlayerChat", getRootElement(), function(msg) if (isObjectInACLGroup("user." .. getAccountName(getPlayerAccount(source)), aclGetGroup("Admin"))) then cancelEvent() outputChatBox("[Admin] " .. getPlayerName(source) .. "#FFFFFF: " .. msg, getRootElement(), 255, 255, 255, true) end end) This one works totally fine.
-
I dont know if you can do it with handlings, but maybe a trick would do with setElementVelocity.
-
Try to replace line nr. 3 with: dxDrawText(v, x*599, y*(473)+(29*ii), x*599+x*350, y*(473)+(29*ii)+y*40, y, tocolor(0, 204, 0, 255), 1.00, dxfont1_AGENCYR, "center", "center", false, false, false, false, false)
-
This does nothing. Just renaming a variable wouldn't do anything. Post your code about the addNotification function.
- 15 replies
-
- notif
- notifacition
- (and 6 more)
-
Disable sprinting if he is not holding space. setControlState(localPlayer, "sprint", false) bindKey("space", "both", function() if getKeyState("space") then setPedControlState(localPlayer, "sprint", true) else setPedControlState(localPlayer, "sprint", false) end end) Should work, not tested tho.
-
Client side, dont even try this on server side. setTimer(function() for i, k in ipairs(getElementsByType("vehicle", getRootElement(), true)) do if downloadFile(getElementModel(k) .. ".txd") then outputChatBox("Updated a file. (MODEL ID: " .. getElementModel(k) .. ")") end end for i, k in ipairs(getElementsByType("object", getRootElement(), true)) do if downloadFile(getElementModel(k) .. ".txd") then outputChatBox("Updated a file. (MODEL ID: " .. getElementModel(k) .. ")") end end end, 5000, 0) Should work, not tested tho.
-
You could just if that model's id has a file for it in the server's download directory. I dunno abait the HTTP download, you gotta test that yourself, but I don't think so.
-
You'll have to set up each model which has to be downloaded, and check for every object/car/item if he moved from his old position, or just by passed time.
-
You could just add it to a renderTarget (via rendering, or just guiimage), and then apply that as the texture of the shader.