Jump to content

papam77

Members
  • Posts

    517
  • Joined

  • Last visited

Everything posted by papam77

  1. MTA Says: Error downloading requested files. Failed to initalize download. Why ?
  2. Nfont = dxCreateFont("font.otf",2) local NfontScale = 2 nametag = {} local enabled = true local nametags = {} local g_screenX,g_screenY = guiGetScreenSize() local bHideNametags = false local NAMETAG_SCALE = 0.3 --Overall adjustment of the nametag, use this to resize but constrain proportions local NAMETAG_ALPHA_DISTANCE = 50 --Distance to start fading out local NAMETAG_DISTANCE = 120 --Distance until we're gone local NAMETAG_ALPHA = 120 --The overall alpha level of the nametag --The following arent actual pixel measurements, they're just proportional constraints local NAMETAG_TEXT_BAR_SPACE = 2 local NAMETAG_WIDTH = 50 local NAMETAG_HEIGHT = 5 local NAMETAG_TEXTSIZE_N = 0.7 local NAMETAG_OUTLINE_THICKNESS = 1.2 -- local chaticon = true local NAMETAG_ALPHA_DIFF = NAMETAG_DISTANCE - NAMETAG_ALPHA_DISTANCE NAMETAG_SCALE = 1/NAMETAG_SCALE * 1100 / g_screenY -- default was 800 -- Ensure the name tag doesn't get too big local maxScaleCurve = { {0, 0}, {3, 3}, {13, 5} } -- Ensure the text doesn't get too small/unreadable local textScaleCurve = { {0, 0.8}, {0.8, 1.2}, {99, 99} } -- Make the text a bit brighter and fade more gradually local textAlphaCurve = { {0, 0}, {25, 100}, {120, 190}, {255, 190} } function nametag.create ( player ) nametags[player] = true end function nametag.destroy ( player ) nametags[player] = nil end dxTextCache = {} dxTextShadowCache = {} function clearDxCache( ) dxTextCache = {} dxTextShadowCache = {} end addCommandHandler("cleardx", clearDxCache) setTimer(clearDxCache,1000,0) function dxDrawColoredText(str, ax, ay, bx, by, color, tcolor, scale, font) local rax = ax if not dxTextShadowCache[str] then dxTextShadowCache[str] = string.gsub( str, '#%x%x%x%x%x%x', '' ) end dxDrawText(dxTextShadowCache[str], ax+1,ay+1,ax+1,by,tocolor(0,0,0, 0.8 * tcolor[4]),scale,font, "left", "bottom", false,false,false) if dxTextCache[str] then for id, text in ipairs(dxTextCache[str]) do local w = text[2] * ( scale / text[4] ) dxDrawText(text[1], ax + w, ay, ax + w, by, tocolor(text[3][1],text[3][2],text[3][3],tcolor[4]), scale, font, "left", "bottom", false,false,false) end else dxTextCache[str] = {} local pat = "(.-)#(%x%x%x%x%x%x)" local s, e, cap, col = str:find(pat, 1) local last = 1 local r = tcolor[1] local g = tcolor[2] local b = tcolor[3] local textalpha = tcolor[4] while s do if cap == "" and col then r = tonumber("0x"..col:sub(1, 2)) g = tonumber("0x"..col:sub(3, 4)) b = tonumber("0x"..col:sub(5, 6)) color = tocolor(r, g, b, textalpha) end if s ~= 1 or cap ~= "" then local w = dxGetTextWidth(cap, scale, font) dxDrawText(cap, ax, ay, ax + w, by, color, scale, font, "left", "bottom") table.insert(dxTextCache[str], { cap, ax-rax, {r,g,b}, scale } ) ax = ax + w r = tonumber("0x"..col:sub(1, 2)) g = tonumber("0x"..col:sub(3, 4)) b = tonumber("0x"..col:sub(5, 6)) color = tocolor( r, g, b, textalpha) end last = e + 1 s, e, cap, col = str:find(pat, last) end if last <= #str then cap = str:sub(last) local w = dxGetTextWidth(cap, scale, font) dxDrawText(cap, ax, ay, ax + w, by, color, scale, font, "left", "bottom") table.insert(dxTextCache[str], { cap, ax-rax, {r,g,b}, scale } ) end end end addEventHandler ( "onClientRender", g_Root, function() -- Hideous quick fix -- for i,player in ipairs(g_Players) do if player ~= g_Me then setPlayerNametagShowing ( player, false ) if not nametags[player] then nametag.create ( player ) end end end if bHideNametags then return end local x,y,z = getCameraMatrix() if not enabled then return end for player in pairs(nametags) do while true do if not isPedInVehicle(player) or isPlayerDead(player) then break end local vehicle = getPedOccupiedVehicle(player) local px,py,pz = getElementPosition ( vehicle ) local pdistance = getDistanceBetweenPoints3D ( x,y,z,px,py,pz ) if pdistance <= NAMETAG_DISTANCE then --Get screenposition local sx,sy = getScreenFromWorldPosition ( px, py, pz+0.95, 0.06 ) if not sx or not sy then break end --Calculate our components local scale = 1/(NAMETAG_SCALE * (pdistance / NAMETAG_DISTANCE)) local alpha = ((pdistance - NAMETAG_ALPHA_DISTANCE) / NAMETAG_ALPHA_DIFF) alpha = (alpha < 0) and NAMETAG_ALPHA or NAMETAG_ALPHA-(alpha*NAMETAG_ALPHA) local scale = math.evalCurve(maxScaleCurve,scale) local textscale = math.evalCurve(textScaleCurve,scale) local textalpha = math.evalCurve(textAlphaCurve,alpha) local outlineThickness = NAMETAG_OUTLINE_THICKNESS*(scale) --Draw chat icon if getElementData(player, "isChatting") and chaticon then -- dxDrawImage(sx - 15 * scale, sy - 40 * scale, 30 * scale, 30 * scale, "img/chat.png") end --Draw our text local r,g,b = 255,255,255 local team = getPlayerTeam(player) if team then r,g,b = getTeamColor(team) end local h = dxGetFontHeight(0.5 * NfontScale * textscale * NAMETAG_TEXTSIZE_N, Nfont) local oet = (scale) * NAMETAG_TEXT_BAR_SPACE/2 local w = dxGetTextWidth(getPlayerName(player), 0.5 * NfontScale * textscale * NAMETAG_TEXTSIZE_N, Nfont) --dxDrawColoredText(getPlayerName(player), sx - w + 1, sy - oet + 1, sx - w + 1, sy + 1, tocolor(0,0,0, math.floor(0.8*getElementAlpha(getPedOccupiedVehicle(player)))),math.floor(0.8*getElementAlpha(getPedOccupiedVehicle(player))), NfontScale * textscale * NAMETAG_TEXTSIZE_N, font, "center", "bottom", false, false, false, true) local a = getElementAlpha(getPedOccupiedVehicle(player)) dxDrawColoredText(getPlayerNametagText(player), sx - w, sy - oet, sx - w, sy, tocolor(r, g, b, a), {r,g,b,a} , NfontScale * textscale * NAMETAG_TEXTSIZE_N, Nfont, "center", "bottom", false, false, false, true) --We draw three parts to make the healthbar. First the outline/background local drawX = sx - NAMETAG_WIDTH*scale*0.65/2 drawY = sy + oet*0.6 local width,height = NAMETAG_WIDTH*scale*0.65, NAMETAG_HEIGHT*scale*0.7 --dxDrawRectangle ( drawX, drawY, width, height, tocolor(0,0,0,alpha) ) --Next the inner background local health = getElementHealth(vehicle) health = math.max(health - 250, 0)/750 local p = -510*(health^2) local r,g = math.max(math.min(p + 255*health + 255, 255), 0), math.max(math.min(p + 765*health, 255), 0) dxDrawImageSection(drawX, drawY, width, height, math.floor(256 - 256 * (health)), 0, 256, 16, "img/healthbar1.png", 0, 0, 0, tocolor(r, g, 0, getElementAlpha(getPedOccupiedVehicle(player)))) dxDrawImageSection(drawX, drawY, width, height, math.floor(256 - 256 * (health)), 0, 256, 16, "img/healthbar2.png", 0, 0, 0, tocolor(255,255,255, getElementAlpha(getPedOccupiedVehicle(player)))) dxDrawImage(drawX - 1, drawY - 1, width + 2, height + 2, "img/healthbar3.png", 0, 0, 0, tocolor(255,255,255,getElementAlpha(getPedOccupiedVehicle(player)))) end break end end end ) addEventHandler('onClientResourceStart', g_ResRoot, function() for i,player in ipairs(getElementsByType"player") do if player ~= g_Me then nametag.create ( player ) end end end ) addEventHandler ( "onClientPlayerJoin", g_Root, function() if source == g_Me then return end setPlayerNametagShowing ( source, false ) nametag.create ( source ) end ) addEventHandler ( "onClientPlayerQuit", g_Root, function() nametag.destroy ( source ) end ) addEvent ( "onClientScreenFadedOut", true ) addEventHandler ( "onClientScreenFadedOut", g_Root, function() bHideNametags = true end ) addEvent ( "onClientScreenFadedIn", true ) addEventHandler ( "onClientScreenFadedIn", g_Root, function() bHideNametags = false end ) function isTheft() return false end setTimer( function() if getElementData(getLocalPlayer(), "isChatting" ) ~= isChatBoxInputActive() then setElementData(getLocalPlayer(), "isChatting", isChatBoxInputActive(), true) end end, 50,0 ) addCommandHandler("nametags", function() enabled = not enabled end ) addCommandHandler("chaticons", function() chaticons = not chaticon end ) Why it doesn't work? I don't see other names on car.
  3. papam77

    SQL Tables

    No. It is correct.
  4. papam77

    SQL Tables

    local serverContainer = {} serverContainer.Settings = {} serverContainer.Settings.user = 'zahrej' serverContainer.Settings.pass = 'hahahah no' serverContainer.Settings.host = 'mysql.mmhost.eu' serverContainer.Settings.name = 'zahrej' serverContainer.startResource = function() local connection = dbConnect('mysql', 'dbname='..serverContainer.Settings.name..';host='..serverContainer.Settings.host, serverContainer.Settings.user, serverContainer.Settings.pass) if connection then outputDebugString('Could connect to the mysql server') serverContainer.connection = connection; else outputDebugString('Couldn\'t connect to the mysql server') end end addEventHandler('onResourceStart', resourceRoot, serverContainer.startResource) serverContainer.loginClient = function(user, pass) local qh = dbQuery(serverContainer.connection,'SELECT * FROM _cwa_users WHERE username = ?',user) local result, row, errmsg = dbPoll ( qh, 5000 ) if row > 0 then for id, result in ipairs(result) do local salt = result['salt'] local username = result['username'] local password = result['password'] if salt and username and password then local newPass = md5(md5(salt):lower()..md5(pass):lower()):lower() if newPass == password then triggerClientEvent(source,'onClientSuccessfullyLogin',source) outputChatBox('#ff6666[sERVER]#ffffff You have successfully login.', source,1,1,1,true) else outputChatBox('#ff6666[sERVER]#ffffff This account doesn\'t exists or the password is wrong.', source,1,1,1,true) end end end end end addEvent('onClientLogins', true) addEventHandler('onClientLogins', root, serverContainer.loginClient) My Tables in mysql: name password What i must change? Because it is writing couldn't connect.
  5. MIKI unblock me on the skype i'll show you. Skype: dee.jay792
  6. function serN(v) sN = v end addEvent("a", true) addEventHandler("a", root, serN) -- Country table -- countryTable = { ['AD'] = 'Andorra', ['AE'] = 'United Arab Emirates', ['AF'] = 'Afghanistan', ['AG'] = 'Antigua and Barbuda', ['AI'] = 'Anguilla', ['AL'] = 'Albania', ['AM'] = 'Armenia', ['AO'] = 'Angola', ['AP'] = 'ARIPO', ['AR'] = 'Argentina', ['AT'] = 'Austria', ['AU'] = 'Australia', ['AW'] = 'Aruba', ['AZ'] = 'Azerbaijan', ['BA'] = 'Bosnia and Herzegovina', ['BB'] = 'Barbados', ['BD'] = 'Bangladesh', ['BE'] = 'Belgium', ['BF'] = 'Burkina Faso', ['BG'] = 'Bulgaria', ['BH'] = 'Bahrain', ['BI'] = 'Burundi', ['BJ'] = 'Benin', ['BM'] = 'Bermuda', ['BN'] = 'Brunei Darussalam', ['BO'] = 'Bolivia', ['BQ'] = 'Bonaire', ['BR'] = 'Brazil', ['BS'] = 'Bahamas', ['BT'] = 'Bhutan', ['BV'] = 'Bouvet Island', ['BW'] = 'Botswana', ['BY'] = 'Belarus', ['BZ'] = 'Belize', ['CA'] = 'Canada', ['CD'] = 'Congo', ['CF'] = 'Central African Republic', ['CG'] = 'Congo', ['CH'] = 'Switzerland', ['CI'] = 'Cote dIvoire', ['CK'] = 'Cook Islands', ['CL'] = 'Chile', ['CM'] = 'Cameroon', ['CN'] = 'China', ['CO'] = 'Colombia', ['CR'] = 'Costa Rica', ['CU'] = 'Cuba', ['CV'] = 'Cape Verde', ['CW'] = 'Curacao', ['CY'] = 'Cyprus', ['CZ'] = 'Czech Republic', ['DE'] = 'Germany', ['DJ'] = 'Djibouti', ['DK'] = 'Denmark', ['DM'] = 'Dominica', ['DO'] = 'Dominican Republic', ['DZ'] = 'Algeria', ['EC'] = 'Ecuador', ['EE'] = 'Estonia', ['EG'] = 'Egypt', ['EH'] = 'Western Sahara', ['ER'] = 'Eritrea', ['ES'] = 'Spain', ['ET'] = 'Ethiopia', ['FI'] = 'Finland', ['FJ'] = 'Fiji', ['FK'] = 'Malvinas', ['FO'] = 'Faroe Islands', ['FR'] = 'France', ['GA'] = 'Gabon', ['GB'] = 'United Kingdom', ['GD'] = 'Grenada', ['GE'] = 'Georgia', ['GG'] = 'Guernsey', ['GH'] = 'Ghana', ['GI'] = 'Gibraltar', ['GL'] = 'Greenland', ['GM'] = 'Gambia', ['GN'] = 'Guinea', ['GQ'] = 'Equatorial Guinea', ['GR'] = 'Greece', ['GT'] = 'Guatemala', ['GW'] = 'Guinea-Bissau', ['GY'] = 'Guyana', ['HN'] = 'Honduras', ['HR'] = 'Croatia', ['HT'] = 'Haiti', ['HU'] = 'Hungary', ['ID'] = 'Indonesia', ['IE'] = 'Ireland', ['IL'] = 'Israel', ['IM'] = 'Isle of Man', ['IN'] = 'India', ['IQ'] = 'Iraq', ['IR'] = 'Iran', ['IS'] = 'Iceland', ['IT'] = 'Italy', ['JE'] = 'Jersey', ['JM'] = 'Jamaica', ['JO'] = 'Jordan', ['JP'] = 'Japan', ['KE'] = 'Kenya', ['KG'] = 'Kyrgyzstan', ['KH'] = 'Cambodia', ['KI'] = 'Kiribati', ['KM'] = 'Comoros', ['KN'] = 'Saint Kitts and Nevis', ['KP'] = 'Korea', ['KR'] = 'Korea', ['KW'] = 'Kuwait', ['KY'] = 'Cayman Islands', ['KZ'] = 'Kazakhstan', ['LA'] = 'Lao Peoples Republic', ['LB'] = 'Lebanon', ['LC'] = 'Saint Lucia', ['LI'] = 'Liechtenstein', ['LK'] = 'Sri Lanka', ['LR'] = 'Liberia', ['LS'] = 'Lesotho', ['LT'] = 'Lithuania', ['LU'] = 'Luxembourg', ['LV'] = 'Latvia', ['LY'] = 'Libyan Arab Jamahiriya', ['MA'] = 'Morocco', ['MC'] = 'Monaco', ['MD'] = 'Moldova', ['ME'] = 'Montenegro', ['MG'] = 'Madagascar', ['MK'] = 'Macedonia', ['ML'] = 'Mali', ['MM'] = 'Myanmar', ['MN'] = 'Mongolia', ['MO'] = 'Macao', ['MP'] = 'Northern Mariana Islands', ['MR'] = 'Mauritania', ['MS'] = 'Montserrat', ['MT'] = 'Malta', ['MU'] = 'Mauritius', ['MV'] = 'Maldives', ['MW'] = 'Malawi', ['MX'] = 'Mexico', ['MY'] = 'Malaysia', ['MZ'] = 'Mozambique', ['NA'] = 'Namibia', ['NE'] = 'Niger', ['NG'] = 'Nigeria', ['NI'] = 'Nicaragua', ['NL'] = 'Netherlands', ['NO'] = 'Norway', ['NP'] = 'Nepal', ['NR'] = 'Nauru', ['NZ'] = 'New Zealand', ['OM'] = 'Oman', ['PA'] = 'Panama', ['PE'] = 'Peru', ['PG'] = 'Papua New Guinea', ['PH'] = 'Philippines', ['PK'] = 'Pakistan', ['PL'] = 'Poland', ['PT'] = 'Portugal', ['PW'] = 'Palau', ['PY'] = 'Paraguay', ['QA'] = 'Qatar', ['RO'] = 'Romania', ['RS'] = 'Serbia', ['RU'] = 'Russian Federation', ['RW'] = 'Rwanda', ['SA'] = 'Saudi Arabia', ['SB'] = 'Solomon Islands', ['SC'] = 'Seychelles', ['SD'] = 'Sudan', ['SE'] = 'Sweden', ['SG'] = 'Singapore', ['SH'] = 'Saint Helena', ['SI'] = 'Slovenia', ['SK'] = 'Slovakia', ['SL'] = 'Sierra Leone', ['SM'] = 'San Marino', ['SN'] = 'Senegal', ['SO'] = 'Somalia', ['SR'] = 'Suriname', ['ST'] = 'Sao Tome and Principe', ['SV'] = 'Salvador', ['SX'] = 'Sint Maarten (Dutch part)', ['SY'] = 'Syrian Arab Republic', ['SZ'] = 'Swaziland', ['TC'] = 'Turks and Caicos Islands', ['TD'] = 'Chad', ['TG'] = 'Togo', ['TH'] = 'Thailand', ['TJ'] = 'Tajikistan', ['TL'] = 'TimorLeste', ['TM'] = 'Turkmenistan', ['TN'] = 'Tunisia', ['TO'] = 'Tonga', ['TR'] = 'Turkey', ['TT'] = 'Trinidad and Tobago', ['TV'] = 'Tuvalu', ['TW'] = 'Taiwan', ['TZ'] = 'Tanzania', ['UA'] = 'Ukraine', ['UG'] = 'Uganda', ['US'] = 'United States of America', ['UY'] = 'Uruguay', ['UZ'] = 'Uzbekistan', ['VA'] = 'Holy See', ['VC'] = 'Saint Vincent', ['VE'] = 'Venezuela', ['VG'] = 'Virgin Islands', ['VN'] = 'Viet Nam', ['VU'] = 'Vanuatu', ['WS'] = 'Samoa', ['YE'] = 'Yemen', ['ZA'] = 'South Africa', ['ZM'] = 'Zambia', ['ZW'] = 'Zimbabwe' } function getMaxPlayers() triggerServerEvent("sendMaxPlayers", localPlayer) end function getMyCash() triggerServerEvent("posliStatsS", root, getLocalPlayer()) end function getCashVysledek(penizky) kesh = penizky end addEvent("posliStatsC", true) addEventHandler("posliStatsC", root, getCashVysledek) function getServerName() triggerServerEvent("a", localPlayer) end local sw, sh = guiGetScreenSize() local showing = false local maxPlayers = getMaxPlayers() local serverName = getServerName() local country = {}
  7. Can you make it please? I can't trigger from center the code.
  8. Hello i have problem with money. client.lua -- Money -- dxDrawText("$" .. getPlayerMoney(v),820*(sw/1920),(((middle+111)*(sh/1080))+((28*(sh/1080))*(#playersWT-1)))+((28*(sh/1080))*(playersCount-1))+((28*(sh/1080))*(teamsi-1)),1534*(sw/1920),447*(sh/1080),tocolor(255,255,255,255),1.8*(sh/1080),"default","left","top",false,false,false) I've made this, but it is getting money from getPlayerMoney and userpanel have own money system bassed on tonumber(getAccountData(account,"cash")) So how can get userpanel's money to my client if getAccountData is serverside.
  9. So i have this php script for it. <?php #--------------------------------------------------# # Script: Flags # # Author: EAG|madA98 # # Date: 14.7. 2013 # # Official site: [url=http://www.mada98.mzf.cz ]www.mada98.mzf.cz [/url] # #--------------------------------------------------# function visitor_country() { $client = @$_SERVER['HTTP_CLIENT_IP']; $forward = @$_SERVER['HTTP_X_FORWARDED_FOR']; $remote = $_SERVER['REMOTE_ADDR']; $result = "Unknown"; if(filter_var($client, FILTER_VALIDATE_IP)) { $ip = $client; } elseif(filter_var($forward, FILTER_VALIDATE_IP)) { $ip = $forward; } else { $ip = $remote; } $ip_data = @json_decode(file_get_contents("http://www.geoplugin.net/json.gp?ip=".$ip)); if($ip_data && $ip_data->geoplugin_countryName != null) { $result = $ip_data->geoplugin_countryName; } return $result; } $visitor_country = visitor_country(); /* Add flags */ if ($visitor_country=='Andorra') {$country=$visitor_country; $flag = '<img src="./flags/ad.png">'} else if ($visitor_country=='United Arab Emirates') {$country=$visitor_country; $flag = '<img src="./flags/ae.png">'} else if ($visitor_country=='Afghanistan') {$country=$visitor_country; $flag = '<img src="./flags/af.png">'} else if ($visitor_country=='Antigua and Barbuda') {$country=$visitor_country; $flag = '<img src="./flags/ag.png">'} else if ($visitor_country=='Anguilla') {$country=$visitor_country; $flag = '<img src="./flags/ai.png">'} else if ($visitor_country=='Albania') {$country=$visitor_country; $flag = '<img src="./flags/al.png">'} else if ($visitor_country=='Armenia') {$country=$visitor_country; $flag = '<img src="./flags/am.png">'} else if ($visitor_country=='Angola') {$country=$visitor_country; $flag = '<img src="./flags/ao.png">'} else if ($visitor_country=='ARIPO') {$country=$visitor_country; $flag = '<img src="./flags/ap.png">'} else if ($visitor_country=='Argentina') {$country=$visitor_country; $flag = '<img src="./flags/ar.png">'} else if ($visitor_country=='Austria') {$country=$visitor_country; $flag = '<img src="./flags/at.png">'} else if ($visitor_country=='Australia') {$country=$visitor_country; $flag = '<img src="./flags/au.png">'} else if ($visitor_country=='Aruba') {$country=$visitor_country; $flag = '<img src="./flags/aw.png">'} else if ($visitor_country=='Azerbaijan') {$country=$visitor_country; $flag = '<img src="./flags/az.png">'} else if ($visitor_country=='Bosnia and Herzegovina') {$country=$visitor_country; $flag = '<img src="./flags/ba.png">'} else if ($visitor_country=='Barbados') {$country=$visitor_country; $flag = '<img src="./flags/bb.png">'} else if ($visitor_country=='Bangladesh') {$country=$visitor_country; $flag = '<img src="./flags/bd.png">'} else if ($visitor_country=='Belgium') {$country=$visitor_country; $flag = '<img src="./flags/be.png">'} else if ($visitor_country=='Burkina Faso') {$country=$visitor_country; $flag = '<img src="./flags/bf.png">'} else if ($visitor_country=='Bulgaria') {$country=$visitor_country; $flag = '<img src="./flags/bg.png">'} else if ($visitor_country=='Bahrain') {$country=$visitor_country; $flag = '<img src="./flags/bh.png">'} else if ($visitor_country=='Burundi') {$country=$visitor_country; $flag = '<img src="./flags/bi.png">'} else if ($visitor_country=='Benin') {$country=$visitor_country; $flag = '<img src="./flags/bj.png">'} else if ($visitor_country=='Bermuda') {$country=$visitor_country; $flag = '<img src="./flags/bm.png">'} else if ($visitor_country=='Brunei Darussalam') {$country=$visitor_country; $flag = '<img src="./flags/bn.png">'} else if ($visitor_country=='Bolivia') {$country=$visitor_country; $flag = '<img src="./flags/bo.png">'} else if ($visitor_country=='Bonaire') {$country=$visitor_country; $flag = '<img src="./flags/bq.png">'} else if ($visitor_country=='Brazil') {$country=$visitor_country; $flag = '<img src="./flags/br.png">'} else if ($visitor_country=='Bahamas') {$country=$visitor_country; $flag = '<img src="./flags/bs.png">'} else if ($visitor_country=='Bhutan') {$country=$visitor_country; $flag = '<img src="./flags/bt.png">'} else if ($visitor_country=='Bouvet Island') {$country=$visitor_country; $flag = '<img src="./flags/bv.png">'} else if ($visitor_country=='Botswana') {$country=$visitor_country; $flag = '<img src="./flags/bw.png">'} else if ($visitor_country=='Belarus') {$country=$visitor_country; $flag = '<img src="./flags/by.png">'} else if ($visitor_country=='Belize') {$country=$visitor_country; $flag = '<img src="./flags/bz.png">'} else if ($visitor_country=='Canada') {$country=$visitor_country; $flag = '<img src="./flags/ca.png">'} else if ($visitor_country=='Congo') {$country=$visitor_country; $flag = '<img src="./flags/cd.png">'} else if ($visitor_country=='Central African Republic') {$country=$visitor_country; $flag = '<img src="./flags/cf.png">'} else if ($visitor_country=='Congo') {$country=$visitor_country; $flag = '<img src="./flags/cg.png">'} else if ($visitor_country=='Switzerland') {$country=$visitor_country; $flag = '<img src="./flags/ch.png">'} else if ($visitor_country=='Cote d?Ivoire') {$country=$visitor_country; $flag = '<img src="./flags/ci.png">'} else if ($visitor_country=='Cook Islands') {$country=$visitor_country; $flag = '<img src="./flags/ck.png">'} else if ($visitor_country=='Chile') {$country=$visitor_country; $flag = '<img src="./flags/cl.png">'} else if ($visitor_country=='Cameroon') {$country=$visitor_country; $flag = '<img src="./flags/cm.png">'} else if ($visitor_country=='China') {$country=$visitor_country; $flag = '<img src="./flags/cn.png">'} else if ($visitor_country=='Colombia') {$country=$visitor_country; $flag = '<img src="./flags/co.png">'} else if ($visitor_country=='Costa Rica') {$country=$visitor_country; $flag = '<img src="./flags/cr.png">'} else if ($visitor_country=='Cuba') {$country=$visitor_country; $flag = '<img src="./flags/cu.png">'} else if ($visitor_country=='Cape Verde') {$country=$visitor_country; $flag = '<img src="./flags/cv.png">'} else if ($visitor_country=='Curacao') {$country=$visitor_country; $flag = '<img src="./flags/cw.png">'} else if ($visitor_country=='Cyprus') {$country=$visitor_country; $flag = '<img src="./flags/cy.png">'} else if ($visitor_country=='Czech Republic') {$country=$visitor_country; $flag = '<img src="./flags/cz.png">'} else if ($visitor_country=='Germany') {$country=$visitor_country; $flag = '<img src="./flags/de.png">'} else if ($visitor_country=='Djibouti') {$country=$visitor_country; $flag = '<img src="./flags/dj.png">'} else if ($visitor_country=='Denmark') {$country=$visitor_country; $flag = '<img src="./flags/dk.png">'} else if ($visitor_country=='Dominica') {$country=$visitor_country; $flag = '<img src="./flags/dm.png">'} else if ($visitor_country=='Dominican Republic') {$country=$visitor_country; $flag = '<img src="./flags/do.png">'} else if ($visitor_country=='Algeria') {$country=$visitor_country; $flag = '<img src="./flags/dz.png">'} else if ($visitor_country=='Ecuador') {$country=$visitor_country; $flag = '<img src="./flags/ec.png">'} else if ($visitor_country=='Estonia') {$country=$visitor_country; $flag = '<img src="./flags/ee.png">'} else if ($visitor_country=='Egypt') {$country=$visitor_country; $flag = '<img src="./flags/eg.png">'} else if ($visitor_country=='Western Sahara') {$country=$visitor_country; $flag = '<img src="./flags/eh.png">'} else if ($visitor_country=='Eritrea') {$country=$visitor_country; $flag = '<img src="./flags/er.png">'} else if ($visitor_country=='Spain') {$country=$visitor_country; $flag = '<img src="./flags/es.png">'} else if ($visitor_country=='Ethiopia') {$country=$visitor_country; $flag = '<img src="./flags/et.png">'} else if ($visitor_country=='Finland') {$country=$visitor_country; $flag = '<img src="./flags/fi.png">'} else if ($visitor_country=='Fiji') {$country=$visitor_country; $flag = '<img src="./flags/fj.png">'} else if ($visitor_country=='Malvinas') {$country=$visitor_country; $flag = '<img src="./flags/fk.png">'} else if ($visitor_country=='Faroe Islands') {$country=$visitor_country; $flag = '<img src="./flags/fo.png">'} else if ($visitor_country=='France') {$country=$visitor_country; $flag = '<img src="./flags/fr.png">'} else if ($visitor_country=='Gabon') {$country=$visitor_country; $flag = '<img src="./flags/ga.png">'} else if ($visitor_country=='United Kingdom') {$country=$visitor_country; $flag = '<img src="./flags/gb.png">'} else if ($visitor_country=='Grenada') {$country=$visitor_country; $flag = '<img src="./flags/gd.png">'} else if ($visitor_country=='Georgia') {$country=$visitor_country; $flag = '<img src="./flags/ge.png">'} else if ($visitor_country=='Guernsey') {$country=$visitor_country; $flag = '<img src="./flags/gg.png">'} else if ($visitor_country=='Ghana') {$country=$visitor_country; $flag = '<img src="./flags/gh.png">'} else if ($visitor_country=='Gibraltar') {$country=$visitor_country; $flag = '<img src="./flags/gi.png">'} else if ($visitor_country=='Greenland') {$country=$visitor_country; $flag = '<img src="./flags/gl.png">'} else if ($visitor_country=='Gambia') {$country=$visitor_country; $flag = '<img src="./flags/gm.png">'} else if ($visitor_country=='Guinea') {$country=$visitor_country; $flag = '<img src="./flags/gn.png">'} else if ($visitor_country=='Equatorial Guinea') {$country=$visitor_country; $flag = '<img src="./flags/gq.png">'} else if ($visitor_country=='Greece') {$country=$visitor_country; $flag = '<img src="./flags/gr.png">'} else if ($visitor_country=='Guatemala') {$country=$visitor_country; $flag = '<img src="./flags/gt.png">'} else if ($visitor_country=='Guinea-Bissau') {$country=$visitor_country; $flag = '<img src="./flags/gw.png">'} else if ($visitor_country=='Guyana') {$country=$visitor_country; $flag = '<img src="./flags/gy.png">'} else if ($visitor_country=='Honduras') {$country=$visitor_country; $flag = '<img src="./flags/hn.png">'} else if ($visitor_country=='Croatia') {$country=$visitor_country; $flag = '<img src="./flags/hr.png">'} else if ($visitor_country=='Haiti') {$country=$visitor_country; $flag = '<img src="./flags/ht.png">'} else if ($visitor_country=='Hungary') {$country=$visitor_country; $flag = '<img src="./flags/hu.png">'} else if ($visitor_country=='Indonesia') {$country=$visitor_country; $flag = '<img src="./flags/id.png">'} else if ($visitor_country=='Ireland') {$country=$visitor_country; $flag = '<img src="./flags/ie.png">'} else if ($visitor_country=='Israel') {$country=$visitor_country; $flag = '<img src="./flags/il.png">'} else if ($visitor_country=='Isle of Man') {$country=$visitor_country; $flag = '<img src="./flags/im.png">'} else if ($visitor_country=='India') {$country=$visitor_country; $flag = '<img src="./flags/in.png">'} else if ($visitor_country=='Iraq') {$country=$visitor_country; $flag = '<img src="./flags/iq.png">'} else if ($visitor_country=='Iran') {$country=$visitor_country; $flag = '<img src="./flags/ir.png">'} else if ($visitor_country=='Iceland') {$country=$visitor_country; $flag = '<img src="./flags/is.png">'} else if ($visitor_country=='Italy') {$country=$visitor_country; $flag = '<img src="./flags/it.png">'} else if ($visitor_country=='Jersey') {$country=$visitor_country; $flag = '<img src="./flags/je.png">'} else if ($visitor_country=='Jamaica') {$country=$visitor_country; $flag = '<img src="./flags/jm.png">'} else if ($visitor_country=='Jordan') {$country=$visitor_country; $flag = '<img src="./flags/jo.png">'} else if ($visitor_country=='Japan') {$country=$visitor_country; $flag = '<img src="./flags/jp.png">'} else if ($visitor_country=='Kenya') {$country=$visitor_country; $flag = '<img src="./flags/ke.png">'} else if ($visitor_country=='Kyrgyzstan') {$country=$visitor_country; $flag = '<img src="./flags/kg.png">'} else if ($visitor_country=='Cambodia') {$country=$visitor_country; $flag = '<img src="./flags/kh.png">'} else if ($visitor_country=='Kiribati') {$country=$visitor_country; $flag = '<img src="./flags/ki.png">'} else if ($visitor_country=='Comoros') {$country=$visitor_country; $flag = '<img src="./flags/km.png">'} else if ($visitor_country=='Saint Kitts and Nevis') {$country=$visitor_country; $flag = '<img src="./flags/kn.png">'} else if ($visitor_country=='Korea') {$country=$visitor_country; $flag = '<img src="./flags/kp.png">'} else if ($visitor_country=='Korea') {$country=$visitor_country; $flag = '<img src="./flags/kr.png">'} else if ($visitor_country=='Kuwait') {$country=$visitor_country; $flag = '<img src="./flags/kw.png">'} else if ($visitor_country=='Cayman Islands') {$country=$visitor_country; $flag = '<img src="./flags/ky.png">'} else if ($visitor_country=='Kazakhstan') {$country=$visitor_country; $flag = '<img src="./flags/kz.png">'} else if ($visitor_country=='Lao People?s Republic') {$country=$visitor_country; $flag = '<img src="./flags/la.png">'} else if ($visitor_country=='Lebanon') {$country=$visitor_country; $flag = '<img src="./flags/lb.png">'} else if ($visitor_country=='Saint Lucia') {$country=$visitor_country; $flag = '<img src="./flags/lc.png">'} else if ($visitor_country=='Liechtenstein') {$country=$visitor_country; $flag = '<img src="./flags/li.png">'} else if ($visitor_country=='Sri Lanka') {$country=$visitor_country; $flag = '<img src="./flags/lk.png">'} else if ($visitor_country=='Liberia') {$country=$visitor_country; $flag = '<img src="./flags/lr.png">'} else if ($visitor_country=='Lesotho') {$country=$visitor_country; $flag = '<img src="./flags/ls.png">'} else if ($visitor_country=='Lithuania') {$country=$visitor_country; $flag = '<img src="./flags/lt.png">'} else if ($visitor_country=='Luxembourg') {$country=$visitor_country; $flag = '<img src="./flags/lu.png">'} else if ($visitor_country=='Latvia') {$country=$visitor_country; $flag = '<img src="./flags/lv.png">'} else if ($visitor_country=='Libyan Arab Jamahiriya') {$country=$visitor_country; $flag = '<img src="./flags/ly.png">'} else if ($visitor_country=='Morocco') {$country=$visitor_country; $flag = '<img src="./flags/ma.png">'} else if ($visitor_country=='Monaco') {$country=$visitor_country; $flag = '<img src="./flags/mc.png">'} else if ($visitor_country=='Moldova') {$country=$visitor_country; $flag = '<img src="./flags/md.png">'} else if ($visitor_country=='Montenegro') {$country=$visitor_country; $flag = '<img src="./flags/me.png">'} else if ($visitor_country=='Madagascar') {$country=$visitor_country; $flag = '<img src="./flags/mg.png">'} else if ($visitor_country=='Macedonia') {$country=$visitor_country; $flag = '<img src="./flags/mk.png">'} else if ($visitor_country=='Mali') {$country=$visitor_country; $flag = '<img src="./flags/ml.png">'} else if ($visitor_country=='Myanmar') {$country=$visitor_country; $flag = '<img src="./flags/mm.png">'} else if ($visitor_country=='Mongolia') {$country=$visitor_country; $flag = '<img src="./flags/mn.png">'} else if ($visitor_country=='Macao') {$country=$visitor_country; $flag = '<img src="./flags/mo.png">'} else if ($visitor_country=='Northern Mariana Islands') {$country=$visitor_country; $flag = '<img src="./flags/mp.png">'} else if ($visitor_country=='Mauritania') {$country=$visitor_country; $flag = '<img src="./flags/mr.png">'} else if ($visitor_country=='Montserrat') {$country=$visitor_country; $flag = '<img src="./flags/ms.png">'} else if ($visitor_country=='Malta') {$country=$visitor_country; $flag = '<img src="./flags/mt.png">'} else if ($visitor_country=='Mauritius') {$country=$visitor_country; $flag = '<img src="./flags/mu.png">'} else if ($visitor_country=='Maldives') {$country=$visitor_country; $flag = '<img src="./flags/mv.png">'} else if ($visitor_country=='Malawi') {$country=$visitor_country; $flag = '<img src="./flags/mw.png">'} else if ($visitor_country=='Mexico') {$country=$visitor_country; $flag = '<img src="./flags/mx.png">'} else if ($visitor_country=='Malaysia') {$country=$visitor_country; $flag = '<img src="./flags/my.png">'} else if ($visitor_country=='Mozambique') {$country=$visitor_country; $flag = '<img src="./flags/mz.png">'} else if ($visitor_country=='Namibia') {$country=$visitor_country; $flag = '<img src="./flags/na.png">'} else if ($visitor_country=='Niger') {$country=$visitor_country; $flag = '<img src="./flags/ne.png">'} else if ($visitor_country=='Nigeria') {$country=$visitor_country; $flag = '<img src="./flags/ng.png">'} else if ($visitor_country=='Nicaragua') {$country=$visitor_country; $flag = '<img src="./flags/ni.png">'} else if ($visitor_country=='Netherlands') {$country=$visitor_country; $flag = '<img src="./flags/nl.png">'} else if ($visitor_country=='Norway') {$country=$visitor_country; $flag = '<img src="./flags/no.png">'} else if ($visitor_country=='Nepal') {$country=$visitor_country; $flag = '<img src="./flags/np.png">'} else if ($visitor_country=='Nauru') {$country=$visitor_country; $flag = '<img src="./flags/nr.png">'} else if ($visitor_country=='New Zealand') {$country=$visitor_country; $flag = '<img src="./flags/nz.png">'} else if ($visitor_country=='Oman') {$country=$visitor_country; $flag = '<img src="./flags/om.png">'} else if ($visitor_country=='Panama') {$country=$visitor_country; $flag = '<img src="./flags/pa.png">'} else if ($visitor_country=='Peru') {$country=$visitor_country; $flag = '<img src="./flags/pe.png">'} else if ($visitor_country=='Papua New Guinea') {$country=$visitor_country; $flag = '<img src="./flags/pg.png">'} else if ($visitor_country=='Philippines') {$country=$visitor_country; $flag = '<img src="./flags/ph.png">'} else if ($visitor_country=='Pakistan') {$country=$visitor_country; $flag = '<img src="./flags/pk.png">'} else if ($visitor_country=='Poland') {$country=$visitor_country; $flag = '<img src="./flags/pl.png">'} else if ($visitor_country=='Portugal') {$country=$visitor_country; $flag = '<img src="./flags/pt.png">'} else if ($visitor_country=='Palau') {$country=$visitor_country; $flag = '<img src="./flags/pw.png">'} else if ($visitor_country=='Paraguay') {$country=$visitor_country; $flag = '<img src="./flags/py.png">'} else if ($visitor_country=='Qatar') {$country=$visitor_country; $flag = '<img src="./flags/qa.png">'} else if ($visitor_country=='Romania') {$country=$visitor_country; $flag = '<img src="./flags/ro.png">'} else if ($visitor_country=='Serbia') {$country=$visitor_country; $flag = '<img src="./flags/rs.png">'} else if ($visitor_country=='Russian Federation') {$country=$visitor_country; $flag = '<img src="./flags/ru.png">'} else if ($visitor_country=='Rwanda') {$country=$visitor_country; $flag = '<img src="./flags/rw.png">'} else if ($visitor_country=='Saudi Arabia') {$country=$visitor_country; $flag = '<img src="./flags/sa.png">'} else if ($visitor_country=='Solomon Islands') {$country=$visitor_country; $flag = '<img src="./flags/sb.png">'} else if ($visitor_country=='Seychelles') {$country=$visitor_country; $flag = '<img src="./flags/sc.png">'} else if ($visitor_country=='Sudan') {$country=$visitor_country; $flag = '<img src="./flags/sd.png">'} else if ($visitor_country=='Sweden') {$country=$visitor_country; $flag = '<img src="./flags/se.png">'} else if ($visitor_country=='Singapore') {$country=$visitor_country; $flag = '<img src="./flags/sg.png">'} else if ($visitor_country=='Saint Helena') {$country=$visitor_country; $flag = '<img src="./flags/sh.png">'} else if ($visitor_country=='Slovenia') {$country=$visitor_country; $flag = '<img src="./flags/si.png">'} else if ($visitor_country=='Slovakia') {$country=$visitor_country; $flag = '<img src="./flags/sk.png">'} else if ($visitor_country=='Sierra Leone') {$country=$visitor_country; $flag = '<img src="./flags/sl.png">'} else if ($visitor_country=='San Marino') {$country=$visitor_country; $flag = '<img src="./flags/sm.png">'} else if ($visitor_country=='Senegal') {$country=$visitor_country; $flag = '<img src="./flags/sn.png">'} else if ($visitor_country=='Somalia') {$country=$visitor_country; $flag = '<img src="./flags/so.png">'} else if ($visitor_country=='Suriname') {$country=$visitor_country; $flag = '<img src="./flags/sr.png">'} else if ($visitor_country=='Sao Tome and Principe') {$country=$visitor_country; $flag = '<img src="./flags/st.png">'} else if ($visitor_country=='Salvador') {$country=$visitor_country; $flag = '<img src="./flags/sv.png">'} else if ($visitor_country=='Sint Maarten (Dutch part)') {$country=$visitor_country; $flag = '<img src="./flags/sx.png">'} else if ($visitor_country=='Syrian Arab Republic') {$country=$visitor_country; $flag = '<img src="./flags/sy.png">'} else if ($visitor_country=='Swaziland') {$country=$visitor_country; $flag = '<img src="./flags/sz.png">'} else if ($visitor_country=='Turks and Caicos Islands') {$country=$visitor_country; $flag = '<img src="./flags/tc.png">'} else if ($visitor_country=='Chad') {$country=$visitor_country; $flag = '<img src="./flags/td.png">'} else if ($visitor_country=='Togo') {$country=$visitor_country; $flag = '<img src="./flags/tg.png">'} else if ($visitor_country=='Thailand') {$country=$visitor_country; $flag = '<img src="./flags/th.png">'} else if ($visitor_country=='Tajikistan') {$country=$visitor_country; $flag = '<img src="./flags/tj.png">'} else if ($visitor_country=='Timor?Leste') {$country=$visitor_country; $flag = '<img src="./flags/tl.png">'} else if ($visitor_country=='Turkmenistan') {$country=$visitor_country; $flag = '<img src="./flags/tm.png">'} else if ($visitor_country=='Tunisia') {$country=$visitor_country; $flag = '<img src="./flags/tn.png">'} else if ($visitor_country=='Tonga') {$country=$visitor_country; $flag = '<img src="./flags/to.png">'} else if ($visitor_country=='Turkey') {$country=$visitor_country; $flag = '<img src="./flags/tr.png">'} else if ($visitor_country=='Trinidad and Tobago') {$country=$visitor_country; $flag = '<img src="./flags/tt.png">'} else if ($visitor_country=='Tuvalu') {$country=$visitor_country; $flag = '<img src="./flags/tv.png">'} else if ($visitor_country=='Taiwan') {$country=$visitor_country; $flag = '<img src="./flags/tw.png">'} else if ($visitor_country=='Tanzania') {$country=$visitor_country; $flag = '<img src="./flags/tz.png">'} else if ($visitor_country=='Ukraine') {$country=$visitor_country; $flag = '<img src="./flags/ua.png">'} else if ($visitor_country=='Uganda') {$country=$visitor_country; $flag = '<img src="./flags/ug.png">'} else if ($visitor_country=='United States of America') {$country=$visitor_country; $flag = '<img src="./flags/us.png">'} else if ($visitor_country=='Uruquay') {$country=$visitor_country; $flag = '<img src="./flags/uy.png">'} else if ($visitor_country=='Uzbekistan') {$country=$visitor_country; $flag = '<img src="./flags/uz.png">'} else if ($visitor_country=='Holy See') {$country=$visitor_country; $flag = '<img src="./flags/va.png">'} else if ($visitor_country=='Saint Vincent') {$country=$visitor_country; $flag = '<img src="./flags/vc.png">'} else if ($visitor_country=='Venezuela') {$country=$visitor_country; $flag = '<img src="./flags/ve.png">'} else if ($visitor_country=='Virgin Islands') {$country=$visitor_country; $flag = '<img src="./flags/vg.png">'} else if ($visitor_country=='Viet Nam') {$country=$visitor_country; $flag = '<img src="./flags/vn.png">'} else if ($visitor_country=='Vanuatu') {$country=$visitor_country; $flag = '<img src="./flags/vu.png">'} else if ($visitor_country=='Samoa') {$country=$visitor_country; $flag = '<img src="./flags/ws.png">'} else if ($visitor_country=='Yemen') {$country=$visitor_country; $flag = '<img src="./flags/ye.png">'} else if ($visitor_country=='South Africa') {$country=$visitor_country; $flag = '<img src="./flags/za.png">'} else if ($visitor_country=='Zambia') {$country=$visitor_country; $flag = '<img src="./flags/zm.png">'}
  10. I wanna get country on server hosted by mmhost.
  11. So i have to do PHP Script with functions to get country by IP ?
  12. I mean that winner is already out from the server and this script has writen his name as the winner. But i won this map.
  13. But i don't http://eag-gaming.eu/uploads/firedoesntwork.png It must be on the wood and nothing.
  14. Position is correct i've put the marker and i've copyied the coordinations.
  15. function DeeJay () outputChatBox ( "#ffffffAve !", getRootElement(), 255, 255, 255, true ) outputChatBox ( "#ffffffActual Year: 0 !", getRootElement(), 255, 255, 255, true ) createFire ( -1972.8114013672, -4087.1137695313, 53.04610824585, 1.8 ) end addEventHandler ("onClientResourceStart",getResourceRootElement(getThisResource()), DeeJay ) Why it doesn't create the fire ? And in text i see hex code, but why ?
  16. DestructionDerby = setmetatable({}, RaceMode) DestructionDerby.__index = DestructionDerby DestructionDerby:register('Destruction derby') function DestructionDerby:isApplicable() return not RaceMode.checkpointsExist() and RaceMode.getMapOption('respawn') == 'none' end function DestructionDerby:getPlayerRank(player) return #getActivePlayers() end -- Copy of old updateRank function DestructionDerby:updateRanks() for i,player in ipairs(g_Players) do if not isPlayerFinished(player) then local rank = self:getPlayerRank(player) if not rank or rank > 0 then setElementData(player, 'race rank', rank) end end end -- Make text look good at the start if not self.running then for i,player in ipairs(g_Players) do setElementData(player, 'race rank', '' ) setElementData(player, 'checkpoint', '' ) end end end function DestructionDerby:onPlayerWasted(player) if isActivePlayer(player) then self:handleFinishActivePlayer(player) if getMapDM() then if getActivePlayerCount() <= 0 then triggerClientEvent ( "showWinMessage", getRootElement()) RaceMode.endMap() -- triggerEvent ( "activatePodium", getRootElement()) else TimerManager.createTimerFor("map",player):setTimer(clientCall, 2000, 1, player, 'Spectate.start', 'auto') end local activePlayers = getActivePlayers() if getActivePlayerCount() == 1 then if getElementModel(getPedOccupiedVehicle(activePlayers[1])) == 425 then setElementHealth(activePlayers[1],0) end end else if getActivePlayerCount() <= 1 then -- triggerClientEvent ( "showWinMessage", getRootElement()) RaceMode.endMap() else TimerManager.createTimerFor("map",player):setTimer(clientCall, 2000, 1, player, 'Spectate.start', 'auto') end end end RaceMode.setPlayerIsFinished(player) showBlipsAttachedTo(player, false) end function DestructionDerby:onPlayerQuit(player) if isActivePlayer(player) then self:handleFinishActivePlayer(player) if getMapDM() then if getActivePlayerCount() <= 0 then RaceMode.endMap() end else if getActivePlayerCount() <= 1 then RaceMode.endMap() end end end end function DestructionDerby:handleFinishActivePlayer(player) -- Update ranking board for player being removed if not self.rankingBoard then self.rankingBoard = RankingBoard:create() self.rankingBoard:setDirection( 'up', getActivePlayerCount() ) end local timePassed = self:getTimePassed() self.rankingBoard:add(player, timePassed) -- Do remove finishActivePlayer(player) -- Update ranking board if one player left local activePlayers = getActivePlayers() if #activePlayers == 1 then self.rankingBoard:add(activePlayers[1], "Winner") callClientFunction(getRootElement(),"setPlayerNameOnWinMessege", activePlayers[1]) triggerEvent("onPlayerDestructionDerbyWin", getRootElement(), activePlayers[1]) end end ------------------------------------------------------------ -- activePlayerList stuff -- function isActivePlayer( player ) return table.find( g_CurrentRaceMode.activePlayerList, player ) end function addActivePlayer( player ) table.insertUnique( g_CurrentRaceMode.activePlayerList, player ) end function removeActivePlayer( player ) table.removevalue( g_CurrentRaceMode.activePlayerList, player ) end function finishActivePlayer( player ) table.removevalue( g_CurrentRaceMode.activePlayerList, player ) table.insertUnique( g_CurrentRaceMode.finishedPlayerList, _getPlayerName(player) ) end function getFinishedPlayerCount() return #g_CurrentRaceMode.finishedPlayerList end function getActivePlayerCount() return #g_CurrentRaceMode.activePlayerList end function getActivePlayers() return g_CurrentRaceMode.activePlayerList end function getMapDM() local getMapName = g_MapInfo.name if string.find(getMapName, "[DM]", 1, true) then return true else return false end end http://eag-gaming.eu/uploads/failwin.png It is writing Crany's name and he was here before 30 minutes. Why it doesn't write my name? I won this map... Don't talk about Hunter reached in the background i must move it down.
  17. But here is little problem. function design () local x,y = guiGetScreenSize() a = 0.23 b = 0.21 c = 0.19 d = 0.04 dxDrawText ( "TEXT",a*x,b*x,c*x,d*x,tocolor(0,255,255,255),1.0,"bankgothic","left","top",false,false,true) end addEventHandler ( "onClientRender", root, design ) http://eag-gaming.eu/uploads/problemeeee.png Label output: guiCreateLabel(0.23, 0.21, 0.19, 0.04, "", true) So why it isn't on the label's place?
  18. Now i don't see it. 0 Errors 0 Warnings
  19. function design () local x,y = guiGetScreenSize() dxDrawText ( "Ahoj",x/2,y/2,x/2,y/2,tocolor(0,255,255,255),1.0,"bankgothic","left","top",false,false,true) end addCommandHandler ("test", design )
  20. bandi94, Thank you very much MIKI785, The code which you've gave me, it's show the image only for 1sec and then is image deleted, but why?
×
×
  • Create New...