-
Posts
6,063 -
Joined
-
Last visited
-
Days Won
209
Everything posted by IIYAMA
-
is your table on top of your code?
-
did you changed the variable somewhere?
-
if it is not in the same file/ not higher in the code, put the table as a global.
-
if isElementInWater ( vehicle ) and not next(getVehicleOccupants (vehicle)) then Vervang deze regel. (regel 4)
-
as I told you before, it is because you don't kill that timer when the player leaves. Nor the table get cleaned.
-
If you don't finish it, of course it will not work... Is this your code? Because you give me the feeling it isn't, since you don't try anything.
-
sorry bro i don't undrestand this can you help me to fix it i'm sorry if i aste ur time . I have no time to write the whole thing bro. But I will recommend you to use 1 timer and getTickCount(). With every timer execution you loop through the whole table and compare the time now with the future time. unmuteTimer[player]=getTickCount()+10000 -- time now + 10 seconds. local timeNow = getTickCount() for player, futureTime in pairs(unmuteTimer) do if isElemenr(player) then if timeNow > futureTime then unmuteTimer[player] = nil setPlayerMuted ( player, false ) end else unmuteTimer[player] = nil end end
-
It seems you aren't reading my post correctly. I am not talking about the mute time, I am hell talking about the player element it self, while leaving an invalid player element is still in the system. onPlayerQuit would work better. Players should not be able to logout if you want your system to work correct.
-
inside the timer block should be a element check. (isElement(player)) If he isn't an element, the timer should be killed and the table should be cleared.
-
@shoBy seriously? You don't even know what you are doing, aren't you? You should do the basic things correctly, before you start with the advanced stuff. Now you are only f.... up your code everytime you edit it. If you don't have time for learning, then stop coding. Wasting your time, wasting our time.
-
O_o"! @Novadex you little bitch
-
blip createBlip ( float x, float y, float z [, int icon = 0, int size = 2, int r = 255, int g = 0, int b = 0, int a = 255, int ordering = 0,[color=#00FF00] float visibleDistance = 99999.0[/color], visibleTo = getRootElement( ) ] ) https://wiki.multitheftauto.com/wiki/CreateBlip
-
no, The getAccounts function will return the results of getPlayerAccount inside a table. Try this out to make it understand able. local accountTable = getAccounts() for index,account in pairs(accountTable) do outputChatBox(index .. " " .. tostring(account) .. " " .. getAccountName(account)) end
-
or you didn't remove that last end. or you have to add a row every time you set an item text, so you have to change the code.
-
I have no idea why the getPedOccupiedVehicle or isPedInVehicle function failed, very strange. I hardly use the isPedInVehicle function, because I always need to know the vehicle element userdata. But this is how I would write it. function speed () local vehicle = getPedOccupiedVehicle (localPlayer) if vehicle then local speedX, speedY, speedZ = getElementVelocity (vehicle) local speed = math.ceil (((speedX^2 + speedY^2 + speedZ^2)^(0.5))*180) dxDrawText (speed.." km/h", x/1.20, y/2.8, x, y, tocolor (255, 255, 255)) end end addEventHandler ("onClientRender", root, speed)
-
I recommend this: for i = 1, 24 do guiGridListAddRow(GUIEditor.gridlist[2]) end -- rest of the code.....
-
Requires an integer. setPedWalkingStyle ( localPlayer, tonumber(id) or 0 ) @Chris!i! What is that loop all about? Doesn't make sense.
-
removeElementData(element,"faction") setElementData(element,"faction",false) I recommend you (if you use that event) to remove the elementdata only when you stop your resource. Also when you start your resource, for every player the elementdata of the key "faction" to false. Because this event does also not triggers if you add elementdata, only when it changes from something to something else.
-
yea, a few smart calculations. About synchronization problems. One of the players will be the syncer, this player will be the one who is going to download and upload with no delay, so it has a little impact at his own network traffic.(and if he lose connection, you can abort the projectile or synced it by somebody else) But for the other players in the server, the projectile is just an effect. Which means if the network can't handle the traffic, you have the choice: send the packet or don't send the packet. Synchronization problems are manage able, if you know how and what functions you have to use. an interval of 300 ms is suit able for the syncer and an interval for other players can be handled with 600 ms. and the reason why I said this all is because circa 7 months ago I started building it, but I never finished it because I started with another resource and I was to lazy to develop it further.
-
Well that depends, everything can be done with lua. You can do the coll checks after the rocket path has been created and during the flying. So yes it is not impossible and high ping maybe annoying. But that is just what it is.
-
The server can synchronize it(serverside >client), except the rocket will never hit anything. The only information the server got, is the streamed element information. So it got disabled most of the time.
-
I had a cheater in my 1.3 server. https://www.dropbox.com/s/r1xi9wjqqvlr0 ... 0.avi?dl=0 He is able to edited his velocity/airbrake. (watch till the end) Cheaters do not get privacy. [2014-09-08 17:53:57] CONNECT: ConTesT[T1] connected (IP: 88.250.163.184 Serial: B6F349555DF1733E1052581A98C20FA1 Version: 1.3.5-9.06531.0) any forum accounts related to this ip? my config: <!-- Comma separated list of disabled anti-cheats. For details see [url=https://wiki.multitheftauto.com/wiki/Anti-cheat_guide]https://wiki.multitheftauto.com/wiki/Anti-cheat_guide[/url] e.g. To disable anti-cheat #2 and #3, use: 2,3 --> <disableac></disableac> <!-- Comma separated list of enabled special detections. A special detection is a type of anti-cheat for (usually) harmless game modifications. Competitive servers may wish to enable special detections, but most servers should leave this setting blank. For details see [url=https://wiki.multitheftauto.com/wiki/Anti-cheat_guide]https://wiki.multitheftauto.com/wiki/Anti-cheat_guide[/url] e.g. To enable special detection #12 use: 12 --> <enablesd></enablesd> <!-- This parameter specifies if/when the <minclientversion> setting is automatically updated. Keeping <minclientversion> updated can help reduce cheating. Note: The instant setting (2) is only recommened for competitive servers. Values: 0 - disabled, 1 - enabled (delayed by a few days), 2 - enabled (instant) ; default value: 1. --> <minclientversion_auto_update>1</minclientversion_auto_update>
-
Well you could check them manualy and if they are you can add in the meta.xml(per resource) a new setting, so you can skip them.