
pa3ck
Members-
Posts
1,141 -
Joined
-
Last visited
-
Days Won
7
Everything posted by pa3ck
-
Yea, but not like that. Radar like GTA 5 has, you will see the roads, buildings etc as well.
-
I've never used this 'function' but give it a try: https://wiki.multitheftauto.com/wiki/DxDrawAnimWindow Remember, its not an MTA function, you will need to copy - paste the whole code and use dxDrawAnimWindow(arguments..) to call the function.
-
Exactly, dxDrawImageSection, but I stuck at the maths part.
-
Shader wont make the map rectangle, it will still be a circle.
-
Hi there, I'm trying to make a new rectangle radar, I know its pretty hard to do it ( for me at least ), I dont know how to go about it. The maths part is the hardest part, hence, I stuck. Any ideas / help on it?
-
Try this: Client: timer = setTimer(function() if isTransferBoxActive() == false then -- Download finished if isTimer(timer) then -- Kill the timer killTimer(timer) setElementData(localPlayer, "downloaded", 1) end else if getElementData(localPlayer, 'downloaded') ~= 0 then -- He is still downloading setElementData(localPlayer, 'downloaded', 0) end end end, 1000, 0) addEventHandler("onClientPlayerDamage", root, function() if getElementData(source, "downloaded") ~= 1 then cancelEvent() end end) addEventHandler("onClientPlayerStealthKill",root, function () if getElementData(source,"downloaded") ~= 1 then cancelEvent() end end)
-
<meta> <script src="scriptname.lua" /> <file src="ak47.txd" /> <file src="ak47.dff" /> </meta> Should be: <meta> <script src="scriptname.lua" type="client"/> <file src="ak47.txd" /> <file src="ak47.dff" /> </meta> If you don't define the type, it's automatically server-side.
-
Okay, both of them do the same thing, mine is just shorter and easier, handier.
-
addEventHandler("onClientGUIClick", root, function () if ( source == Radyobutton1 ) then if isElement(sound) then stopSound(sound) end sound = playSound( "****", false ) elseif ( source == Radyobutton2 ) then if isElement(sound) then stopSound(sound) end sound = playSound( "**", false ) elseif ( source == Radyobutton3 ) then if isElement(sound) then stopSound(sound) end sound = playSound( "***", false ) elseif ( source == Radyobutton4 ) then if isElement(sound) then stopSound(sound) end sound = playSound( "****", false ) elseif ( source == radkapat ) then if isElement(sound) then stopSound(sound) end end end)
-
If you dont want to do it yourself, use this resources: https://community.multitheftauto.com/ind ... ls&id=7725 Otherwise, you will need addCommandHandler bindKey and outputChatBox
-
You should read the description: "This superman script is not for all players, i modify it only for the team: Admins. I saw some superman who are restricted but it's not working so i made mine. I just added a fonction: local function canFly() return getTeamName(getPlayerTeam(getLocalPlayer())) == "Admins" end"
-
Because that functions draws you screen source, which is not as good as a real screen. There is no way to fix it, you will need to manually disable the HUD.
-
Thank you, but I was right, there's a built in function: bindKey("b", "down", "chatbox", "Name")
-
Morning, I've made a new chatbox, and what I want to do is that I'll bind it to a key. As far as I know ( I don't know why I think this, I might be wrong ) there's some way to do that, just like you would press "t" and as you type, you will see the text under your default chatbox. Am I right? Is that possible?
-
Very impressing! Also I would ask a question if possible. Is there any way to change the pie chart to lets say bar chart or venn diagram?
-
Oh yea, you're right! Thanks!
-
Hi there, I'm having trouble with my little code. It works, but for some reason it spams the chat and gives me an error saying that "C stack overflow" addEventHandler("onClientElementDataChange", root, function ( name, oldValue ) if getElementType(source) == "player" then local protected = getElementData(source, "protected") or 0 if protected == 0 then outputChatBox("Element data was changed back to old value.", 255, 0, 0) newValue = getElementData(source, name, value) setElementData(source, name, oldValue) end end end) Any help?
-
Get the resolution first with guiGetScreenSize, then calculate the position from the two numbers you got. You might want to read this https://wiki.multitheftauto.com/wiki/Int ... the_window
-
Compile your script, then they can't steal it easily. GUI, DX and stuff like that are all client-side only functions, can not be done server-side.
-
local x, y, w, h, image = 0, 0, 150, 50, "image.png" function drawImage() dxDrawImage(x, y, w, h, image) end addEventHandler("onClientRender", root, drawImage) setTimer(function() removeEventHandler("onClientRender", root, drawImage) end, 15000, 1)-- Stops rendering the image after 15000 ms (15 sec)
-
Actually it's nothing to do with the cancelEvent(), I just used that as an example. I want to set the element data of the source ( the ped that was shot ). EDIT: LOL, I'm silly again, fixed, thanks anyways!
-
No difference, it's not triggered.
-
Hi there, I have some funny problems here, I got a simple code like this: addEventHandler("onClientPedDamage", getRootElement(), function() cancelEvent() end) Whatever I do in the function, it does nothing at all, the event is not triggered I think... What are the possible things, that could prevent the event to be triggered?
-
Just use setWeaponProperty
-
Use triggerServerEvent with 'getRootElement()' then trigger a client event back using triggerClientEvent with 'getRootElement()' and use playSound3D insted of playSound