-
Posts
767 -
Joined
-
Last visited
Everything posted by Xierra
-
Tested, and actually it didn't work. So anyone has the solution?
-
Ahh that's right, I'll try it tomorrow. Btw, what about reappearing it again? Was it addEventHandler to the same function?
-
Nice tip! I think some people who wanted to use their custom lobby is a good thing.
-
So, how should I fix that? It's 100% DX drawings you know.
-
Hi there, I started working back on the Alternate HUD. Since I got lots of "if" "elseif" and "else" commands I got a bit stuck at this: How to remove all part of the alternate HUD by just using a command? Script: -- Made By XX3, from scratch with MS Notepad. Purpose: To make a new exotic compact HUD. -- You may edit this resource, but please credit me if you wanted to post an edited / extended version. -- Weapon tables for ammo. local noreloadweapons = {} --Weapons that doesn't reload (including the flamethrower, minigun, which doesn't have reload anim). noreloadweapons[16] = true noreloadweapons[17] = true noreloadweapons[18] = true noreloadweapons[19] = true noreloadweapons[25] = true noreloadweapons[33] = true noreloadweapons[34] = true noreloadweapons[35] = true noreloadweapons[36] = true noreloadweapons[37] = true noreloadweapons[38] = true noreloadweapons[39] = true noreloadweapons[41] = true noreloadweapons[42] = true noreloadweapons[43] = true local meleespecialweapons = {} --Weapons that don't shoot, and special weapons. meleespecialweapons[0] = true meleespecialweapons[1] = true meleespecialweapons[2] = true meleespecialweapons[3] = true meleespecialweapons[4] = true meleespecialweapons[5] = true meleespecialweapons[6] = true meleespecialweapons[7] = true meleespecialweapons[8] = true meleespecialweapons[9] = true meleespecialweapons[10] = true meleespecialweapons[11] = true meleespecialweapons[12] = true meleespecialweapons[13] = true meleespecialweapons[14] = true meleespecialweapons[15] = true meleespecialweapons[40] = true meleespecialweapons[44] = true meleespecialweapons[45] = true meleespecialweapons[46] = true function DXdraw() --Variables sWidth, sHeight = guiGetScreenSize() health = getElementHealth( getLocalPlayer() ) lineLength1 = 114 * ( health / 100 ) -- Health bar armor = getPedArmor( getLocalPlayer() ) lineLength2 = 114 * ( armor / 100 ) -- Armor bar ammoinclip = getPedAmmoInClip (getLocalPlayer()) totalammo = getPedTotalAmmo (getLocalPlayer()) showammo1 = ammoinclip showammo2 = totalammo moneycount=getPlayerMoney(getLocalPlayer()) money= '$' ..moneycount local hour, mins = getTime () time = hour .. ":" .. (((mins < 10) and "0"..mins) or mins) -------- Dynamic health colour thanks to 50p ---------- tick = getTickCount () -- For active health bar local maxHealth = 100; -- get max health stat local colourPercent = ( health / maxHealth ) * 200; local red, green; -- we don't need blue because we don't use it, it'll be 0 if health < ( maxHealth / 2 ) then red = 200; green = ( health / 50 ) * ( colourPercent * 2 ); else green = 200; red = 200 - ( ( health - 50 ) / 50 ) * 200; end -- For inactive health bar local maxHealth = 75; -- get max health stat local colourPercent1 = ( health / maxHealth ) * 75; local red1, green1; -- we don't need blue because we don't use it, it'll be 0 if health < ( maxHealth / 2 ) then red1 = 75; green1 = ( health / 50 ) * ( colourPercent1 * 2 ); else green1 = 75; red1 = 75 - ( ( health - 50 ) / 50 ) * 75; end local color1 = tocolor( red1, green1, 0, 150 ) local color2 = tocolor( red, green, 0, 200 ) -- For the health bar if getTickCount () %1500 < 500 and health <= 25 then else dxDrawRectangle(sWidth-206,sHeight-23,114.0,14.0,color1, false) -- Health inactive bar dxDrawRectangle(sWidth-206,sHeight-23,lineLength1,14.0,color2,false) --Health active bar end if armor <= 0 then else dxDrawRectangle(sWidth-206,sHeight-43,lineLength2,14.0,tocolor(200,200,200,200),false) -- Armor active bar dxDrawRectangle(sWidth-206,sHeight-43,114.0,14.0,tocolor(50,50,50,150),false) -- Armor inactive bar end ------ DX drawing that are visible at all times dxDrawRectangle(sWidth-84,sHeight-48,78.0,33.0,tocolor(0,0,0,150),false) -- GTA Time DX Rectangle dxDrawText(tostring (money),sWidth-200,sHeight-78,sWidth-5,sHeight-54,tocolor(0,0,0,200),1.0,"pricedown","right","top",false,false,false) -- Money DX text (shadow) dxDrawText(tostring (money),sWidth-202,sHeight-81,sWidth-7,sHeight-57,tocolor(0,100,0,220),1.0,"pricedown","right","top",false,false,false) -- Money DX text dxDrawText(tostring (time),sWidth-81,sHeight-46,sWidth-10,sHeight-16,tocolor(250,250,250,200),1.0,"diploma","center","top",false,false,false) -- GTA Time DX text ------- Weapon icons & Ammo DX drawings local weaponID = getPedWeapon (getLocalPlayer()); -- Get weapon ID dxDrawImage(sWidth-266,sHeight-56,48.0,52.0,"icons/".. tostring( weaponID ) .. ".png",0.0,0.0,0.0,tocolor(255,255,255,200),false) -- Weapon icons image. -- now decide if the optional stuff should be drawn if noreloadweapons [getPedWeapon(getLocalPlayer())] then dxDrawText(tostring (showammo2),sWidth-400,sHeight-42,sWidth-288,sHeight-12,tocolor(0,255,255,200),1.0,"bankgothic","right","top",false,false,false) -- No reload weapons (for shotgun, grenades, etc) elseif meleespecialweapons [getPedWeapon(getLocalPlayer())] then -- Draw Nothing for melee and special weapons. else --Weapons that reloads. dxDrawText(tostring (showammo1),sWidth-455,sHeight-41,sWidth-387,sHeight-13,tocolor(0,255,255,200),1.0,"bankgothic","right","top",false,false,false) dxDrawText("|",sWidth-381,sHeight-42,sWidth-366,sHeight-8,tocolor(255,200,0,200),1.0,"bankgothic","left","top",false,false,false) dxDrawText(tostring (showammo2),sWidth-365,sHeight-41,sWidth-272,sHeight-12,tocolor(0,255,255,200),1.0,"bankgothic","left","top",false,false,false) end end -- End of the DX Drawing function addEventHandler("onClientRender", getRootElement(), DXdraw) -- Show / Hide GTA SA HUD command function. function hudChanger () showPlayerHudComponent ( "armour", false ) showPlayerHudComponent ( "health", false ) showPlayerHudComponent ( "money", false ) showPlayerHudComponent ( "clock", false ) showPlayerHudComponent ( "weapon", false ) showPlayerHudComponent ("ammo", false) showPlayerHudComponent ( "money", false ) end addCommandHandler ( "hidehud", hudChanger ) addEventHandler( "onClientResourceStart", getRootElement(), hudChanger ) -- Hide the HUD (except oxygen) on resource start. addEventHandler( "onPlayerJoin", getRootElement(), hudChanger ) -- The same, but also on player join. function hudChanger2 () showPlayerHudComponent ( "armour", true ) showPlayerHudComponent ( "health", true ) showPlayerHudComponent ( "money", true ) showPlayerHudComponent ( "clock", true ) showPlayerHudComponent ( "weapon", true ) showPlayerHudComponent ("ammo", true) showPlayerHudComponent ( "money", true) end addCommandHandler ( "showhud", hudChanger2) -- Show all the HUD if you want to. Since I'm still a scripting newbie, I might not know how to do it. So any help is appreciated. PS: Where are all the LUA function colors?
-
Ahh yes, thanks to this, I learnt about the doppler effect. That statement made me understand.
-
Nope there isn't. But from MTA Race 1.1 to MTA SA 1.0.x, there is.
-
Umm, what does doppler mean? I'm not a sound specialist...
-
Hi guys! I have a new great idea, when I used manual, an idea pop out of my head. So here it is, sound pitch. I have been using manual and it's awesome, but, the car engine sound doesn't sync with the manual gear change, it just sticks according to time, poor R*. So by using a sound pitch, we could use it to make use of custom car engine sounds. By this way + RPM system + gear sync, there would be 5x more awesome. Also, I wanted an option to turn on/off original R* car engine sounds, so there will be no double engine sounds. What do you guys think about that?
-
Good idea, but steam would be a good solution too.
-
I'm even worse, I haven't even learnt this at all! (Because, I'm still in Junior High School)
-
Wow! One next step for the realistic city, driving bots. Could be useful for non-skipping taxi driving with a bot. (As seen on DP2's Simbad's server taxi service, it just skips right to the destination.) That's one daring step to go. PS: The first video's music was like my country's national song.
-
Wow! Mario kart in MTA SA? Awesome! Well done on your work with the ? boxes. Suggestions: You should make the boxes much bigger, and also change the position of the item you get, put it on the edge, it would be nice not to block the screen.
-
Little help (gas stations, useful objects,ppl for beta-test)
Xierra replied to dzek (varez)'s question in Client
I'm in on mapping stunts. My ultimate idea: Make a basketcar map, to replace the basketball which was used in the GTA SA. Someone should be able to script the scores later... And also I'll try finding the gas stations. What about beta testing? I can test, but what part of gamemode? -
like selfpromotion> Exactly! The Garry Ware (Gmod) ---> MTA Ware (MTA SA) is one of the examples what I meant. There's lots of more gamemodes than this though. What's your evil plans?
-
Nice idea for creating Green Zone. This kind of resource was not in the community yet, you can try making the english version and upload it. Everyone would like it.
-
Hmm, thinking of the scripting, Gmod also uses LUA language as their scripts language. Why not try inviting Gmod scripters here and try making Gmod-like scripts? That would be nice.
-
I wish I could master the LUA language. Why not make it the Whole San Andreas instead? If they could, the server will be even better than most of the SA-MP's RP servers (which only has one city per server).
-
I can tell what's happening as it's the same problem in the -RoCk- clan. So what's he's talking about is the "Force Vote". Means you must choose that one and you can't say "don't want either of them". In this case, the players (even if they're not admin), they can vote /arena 20 20 or /base 12 12 and so on. And it's not bug, he just didn't put it. Layout of vote after that: ------------------------------------------------------ Please Choose a vote 1. Arena 20 2. Arena 20 Press Backspace to cancel ------------------------------------------------------ That's what will happen. They were forced to choose Arena 20 in any way and you can't cancel it. Rhbk should add an option not to choose either of them in the next release. We just have to wait until he released his next project or source code.
-
Here comes a new challenger!
-
Gonna test the Combobox soon. Nice work, as R3mp hasn't even put this feature on his guieditor yet!
-
Can you give me what's inside the .map file? Just one of them is enough. Or give the link so we can see what's inside. Btw, if there's only map file, I think I sense that those are the MTA Race .map files. You need to export it to the ones compatible with 1.0 or higher. If it's an MTA Race map, follow these steps: 1. Download the MTA Race map -> MTA SA 1.0.x batch converter and extract it to a new folder or anywhere you want. 2. Extract the maps to a new seperate folder or your MTA Race maps folder. 3. Open the batch converter 4. There are 2 buttons: MTA Race maps and MTA 1.0 Resources Click the MTA race maps folder and locate your maps folder as I said on step 2. Now click the MTA 1.0 Resources button and locate your MTA 1.0.x resources folder (X:\Program Files\MTA San Andreas\Server\Mods\Deathmatch\resources) 5. Finally, click Convert. It will start converting. 6. Finished, and you can use it to play in MTA 1.0.x. Enjoy. WARNING : If you want to edit the pickups & spawnpoints, don't convert it first. Because you can't move the pickups anymore after you convert it. You should edit that in MTA Race Map editor.
-
Check again. It's actually working. Just ignore the "on construction" words.
-
Hmm, I don't know about this, so you could ask someone else, maybe they can help you. Maybe you can try find the settings of the "Fly With Mouse". That setting determines if steering is possible with mouse or not.
