proracer
Members-
Posts
499 -
Joined
-
Last visited
Everything posted by proracer
-
Any errors? Did you put 3 images correctly there and named them as it is in the table: "randomImages"?
-
In race/race_client.lua, go to line: 132-140 - you should see TravelScreen.init function. Try it replace with this: function TravelScreen.init() local screenWidth, screenHeight = guiGetScreenSize() local randomImages = {'img/travelling1.png','img/travelling2.png','img/travelling3.png'} g_GUI['travelImage'] = guiCreateStaticImage(screenWidth/2-256, screenHeight/2-90, 512, 256, tostring(randomImages[math.random(1,3)]), false, nil) g_dxGUI['travelText1'] = dxText:create('Travelling to', screenWidth/2, screenHeight/2-130, false, 'bankgothic', 0.60, 'center' ) g_dxGUI['travelText2'] = dxText:create('', screenWidth/2, screenHeight/2-100, false, 'bankgothic', 0.70, 'center' ) g_dxGUI['travelText1']:color(240,240,240) hideGUIComponents('travelImage', 'travelText1', 'travelText2') end Also you must have 3 pictures: travelling1.png,travelling2.png etc... you can change however you want.
-
Firstly, getElementsByName doesn't exist. Replace it again as you did in your first post with getElementsByType. Also it's weird that you didn't understood why it's a nil value... you could search easily for that function and you could see that it doesn't exist, so you seem very suspicious. There's an error with creating the objects in specified area, it's not error with the object.
-
I don't think you made it.You say that you're noob .. if so then you wouldn't make so much "advanced" script. /me thinks this is stolen Also you forgot comma on the line 20.
-
Try this. function lockcar ( ) local x = -682.4951171875 local y = 952.8115234375 local z = 12.1328125 createVehicle ( 432, x, y, z ) setElementData ( getLocalPlayer(), 'kimmis9' ) end addEventHandler ( 'onClientResourceStart', resourceRoot, lockcar )
-
Did you even created a table?
-
Yes he's from Croatia like me and he asks for an explanation...
-
Can't you search ...? https://community.multitheftauto.com/index.php?p=resources
-
Probably not .. it's not a resource that comes with MTA.
-
There is already default resource: "race" and in there file called: "fancyprogress.lua" - there you can find it. Also the nametags.lua has it too.
-
Oh, sorry then..
-
Why are you using serverside code? All the codes is also available in clientside.
-
In meta.xml, script type is server not client.
-
Sorry for double post, I worked hard on this but I still can't figure out this: So .. when player clicks button it draws avatar above his head.But when player clicks button again with different avatar it draws an image over it, how can I fix that? Because I have 100+ avatars ..
-
It's not wrong... https://wiki.multitheftauto.com/wiki/GetResourceRootElement
-
function respawnVehicles ( ) for i,v in ipairs ( getElementsByType ( 'vehicle' ) ) do setVehicleRespawnDelay ( v, 5000 ) end end addEventHandler ( 'onResourceStart', resourceRoot, respawnVehicles )
-
Maybe you can load default infernus txd?
-
https://wiki.multitheftauto.com/wiki/SetAccountData
-
You can use: https://wiki.multitheftauto.com/wiki/SetAccountData or with xml or sql. But setAccountData is easiest by far now.
-
If I understood correctly, it shouldn't appear when you are not AFK...
-
@Citizen: Sorry, I was writing fast .. ^^
-
root is already defined as a keyword in MTA:
-
function fixPlayerVeh ( ) local veh = getPedOccupiedVehicle ( source ) if (not veh) then return if (getElementHealth(veh)) == 1000 then outputChatBox ( "Your Vehicle doesn't need to be fixed.", source ) -- not sure if this is max health (could be 100 or 1000) else fixVehicle ( veh ) end end end end addEventHandler ( 'br', fixPlayerVeh )
-
Are you kidding me?! You can try to uncompile yourself if it's possible, otherwise there was a purpose that script is compiled.
