-
Posts
118 -
Joined
-
Last visited
Everything posted by mehmet
-
Well, I have a shader. Can you show an example script? (I found the script, but the code is closed) and you can still like to add lighting to the turn signal? (as on the screen)
-
Hello, how to make a system of turn signals? (using car textures)
-
stop, which method is better? addEventHandler("onPlayerChat", getRootElement(), function(message) cancelEvent() local x, y, z = getElementPosition(source) local radius = createColSphere(x, y, z, 15) -- see the message in 15m radius local nearPlayers = getElementsWithinColShape(radius, "player") destroyElement(radius) for _, player in ipairs(nearPlayers) do if getElementDimension(player) == getElementDimension(source) then outputChatBox(getPlayerName(source)..": #FFFFFF"..message, player, 255, 255, 255, true) end end end) OR -- define our chat radius local chatRadius = 20 --units -- define a handler that will distribute the message to all nearby players function sendMessageToNearbyPlayers(message, messageType) -- we will only send normal chat messages, action and team types will be ignored if messageType == 0 then -- get the chatting player's position local posX1, posY1, posZ1 = getElementPosition(source) -- loop through all player and check distance for id, player in ipairs(getElementsByType("player")) do local posX2, posY2, posZ2 = getElementPosition(player) if getDistanceBetweenPoints3D(posX1, posY1, posZ1, posX2, posY2, posZ2) <= chatRadius then outputChatBox(message, player) end end end -- block the original message by cancelling this event cancelEvent() end -- attach our new chat handler to onPlayerChat addEventHandler( "onPlayerChat", getRootElement(), sendMessageToNearbyPlayers )
-
Is this method slow? createColSphere List of players available on the client? (Список игроков можно получить на клиенте?)
-
And on the client side, you can? Почему похоронит? И мог бы объяснить на какой части это лучше делать? на клиентской или серверной
-
Why server side?
-
Thank you, but I decided to use an image.?
-
can CEF be better?
-
I make the menu. If rendering 100-200 rectangle is a lot? (1 button = 9 Rectangle)
-
Is this method better?
-
Hello, I want to create a button with rounded corners. Pictures will not work. I need to create a dynamic button. How to do it right? and well optimized. They say this is a bad way for server performance. + visible pixels ( local x,y = guiGetScreenSize() local sx,sy = 400,200 local size = 45 -- pixel size to cut function performRendering() for i=1,sy do local dg = math.min(i,size) -- limit it to the size if i > sy-size then dg = sy-math.max(sy-size,i) -- limit it to the size for bottom parts end local csx = sx-1/dg*size -- use our lovely y = k/x function dxDrawRectangle(x/2-csx/2,y/2-sy/2+i,csx,1,tocolor(0,0,0,200)) -- draw the magic at the middle end end addEventHandler("onClientRender",getRootElement(),performRendering)
-
I thought it was okay.))
-
how much did you buy the mod? I bought this mod for 150-180 dollars. and the author promised to sell only to me.
-
Hello, where can I get documentation by "debug". debug.getinfo debug.traceback and etc. Thank you in advance!
-
Hello, where can I get documentation by "debug". debug.getinfo debug.traceback and etc. Thank you in advance!
-
addEventHandler( "onResourceStart", resourceRoot, function() setLowLODElement ( objNormal, objLowLOD ) end ) for i, v in ipairs(getElementsByType("object")) do local model = getElementModel(v) engineSetModelLODDistance(model, 300) -- Set maximum draw distance end So?
-
Hello, everybody. Distance of drawing trees, boxes, fence, other small objects. how to increase the range of the drawing? addEventHandler( "onResourceStart", resourceRoot, function( ) setFarClipDistance( 3000 ) -- We adjust visibility range to 3000 metres end) It doesn't help.
-
Hi guys, I want to make a fuel system. As I understand it better to do this on the server side. So that they could not change the values. Yes? And is it possible to do without getElementData? For example, using the table