Jump to content

ReSe

Members
  • Posts

    23
  • Joined

  • Last visited

Details

  • Gang
    DDAS
  • Location
    Poland

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

ReSe's Achievements

Civilian

Civilian (7/54)

0

Reputation

  1. ReSe

    Image placing

    You have to declare size of your image. It's pixel size so if your width of screen is variable "x" and you would like to show image on center then you have to do some math: "x/2 - halfsizeofimage" Place img on center: local x, y = guiGetScreenSize() function showClientImage() guiCreateStaticImage( x/2-100, y/2-100, 200, 200, "logo1.png", false ) end addEventHandler( "onClientResourceStart", getResourceRootElement( getThisResource() ), showClientImage ) You should read description of guiCreateStaticImage function. First argument is horizontal position on screen, 2nd arg is vertical position, 3rd is width of ig, 4rd is height, ..."
  2. ReSe

    Image placing

    Hmm here's pic of your script. I guess your monitor have native resolution of 1080p. You should first get size of screen and then place an img //Ok here's code if you don't understand. That should make it working local x, y = guiGetScreenSize() function showClientImage() guiCreateStaticImage( x-100, y-100, 100, 100, "logo1.png", false ) end addEventHandler( "onClientResourceStart", getResourceRootElement( getThisResource() ), showClientImage )
  3. Do not exaggerate. A script that is huge doesn't mean it has more potential than a script with less lines but with the same functionality Did I say anything like that? I said it's huge and it have lot of potential. You should read my words twice. You must be kidding, how many loc per day do you write on average? 5? Hm.. Is your advanced script "Object-Oriented" or "Process-Oriented"? In case it is the second you cannot call it advanced imo 5 * 4 * 31 = 620 lines. That's like nothing. Man, there are days when you can stuck in some place trying to find best solution. Really don't "judge" if you didn't experience it. And no it's not process-oriented.
  4. No problem I can post some ss but the best way is to see it on DDAS server. I've create player panel based on dxGui resource. It's really huge script with a lot of potential. It was designed to work with DD/DM/Race. Different kind of achievements, statistics for every mode. That's the most advanced script I've made so far. Took me about 4 months. Mostly I've been making scripts to DD and DM modes. If you really would like to see some of my work here I would make a video and send you url from youtube
  5. You mean you would like to count players?
  6. It's pretty simple but I don't think anyone will do it for free. It needs good way to display requests for staff and a way to remove then from list. Best way is separate dxDraw window. Since im low on cash I would make it for few $$ Text me on skype if you're interested. skype: patryk_gs
  7. ReSe

    count dxdraw

    Mhm try to copy it one more time. Client i = nil local x, y = guiGetScreenSize() function triggerDraw(ID) i = ID if i == 3 then drawBegin() elseif i < 0 then drawStop() return end playSound( i..".mp3", false ) end addEvent ( "triggerclientforGridCountdown", true ) addEventHandler ( "triggerclientforGridCountdown", getRootElement(), triggerDraw ) function drawOnScreen() if not i then return end if i > 0 then dxDrawText("#FF0000==="..i.."===",0,0,x,y, tocolor(0,0,0,255), 2, "bankgothic", "center", "center", false, false, true, true) else dxDrawText("#FF0000Go Go Go!!!",0,0,x,y, tocolor(0,0,0,255), 2, "bankgothic", "center", "center", false, false, true, true) end end function drawBegin() addEventHandler( "onClientRender", getRootElement(), drawOnScreen) end function drawStop() removeEventHandler( "onClientRender", getRootElement(), drawOnScreen) end //Owh nvm
  8. ReSe

    count dxdraw

    You sure You've copy everything fine?
  9. ReSe

    count dxdraw

    I've fixed it already. Just change "soundID" with "i"
  10. ReSe

    count dxdraw

    If you want sound change triggerDraw function in client with that one function triggerDraw(ID) i = ID if i == 3 then drawBegin() elseif i < 0 then drawStop() return end sound = playSound( i..".mp3", false ) end addEvent ( "triggerclientforGridCountdown", true ) addEventHandler ( "triggerclientforGridCountdown", getRootElement(), triggerDraw )
  11. ReSe

    count dxdraw

    Server timers = {} function Countdown (player) if isTimer(timers[player]) then return end timers[player] = setTimer(function() timers[player] = nil end,30000,1) local name = getPlayerName(player) local r,g,b = getPlayerNametagColor (player) outputChatBox ( " ".. name .. ": #FF9600 Starts the Countdown !", getRootElement(), r, g, b, true ) local i = 4 setTimer( function() i=i-1 triggerClientEvent("triggerclientforGridCountdown", getRootElement(), i) if (i==0) then outputChatBox ( "#FF0000 Go Go Go!!!", getRootElement(), 255, 255, 255, true ) return elseif i > 0 then outputChatBox ( "#FF0000 ==="..i.."===", getRootElement(), 255, 255, 255, true ) end end, 1000, 5 ) setTimer (function() timers[player] = nil end, 30000, 1) end addCommandHandler( "countdown", Countdown ) Client i = nil local x, y = guiGetScreenSize() function triggerDraw(ID) i = ID if i == 3 then drawBegin() elseif i < 0 then drawStop() end end addEvent ( "triggerclientforGridCountdown", true ) addEventHandler ( "triggerclientforGridCountdown", getRootElement(), triggerDraw ) function drawOnScreen() if not i then return end if i > 0 then dxDrawText("#FF0000==="..i.."===",0,0,x,y, tocolor(0,0,0,255), 2, "bankgothic", "center", "center", false, false, true, true) else dxDrawText("#FF0000Go Go Go!!!",0,0,x,y, tocolor(0,0,0,255), 2, "bankgothic", "center", "center", false, false, true, true) end end function drawBegin() addEventHandler( "onClientRender", getRootElement(), drawOnScreen) end function drawStop() removeEventHandler( "onClientRender", getRootElement(), drawOnScreen) end
  12. ReSe

    count dxdraw

    You want to show it on screen? Not in chat?
  13. ReSe

    count dxdraw

    Server timers = {} function Countdown (player) if isTimer(timers[player]) then return end timers[player] = setTimer(function() timers[player] = nil end,30000,1) local name = getPlayerName(player) local r,g,b = getPlayerNametagColor (player) outputChatBox ( " ".. name .. ": #FF9600 Starts the Countdown !", getRootElement(), r, g, b, true ) local i = 4 setTimer( function() i=i-1 triggerClientEvent("triggerclientforGridCountdown", getRootElement(), i) if (i==0) then outputChatBox ( "#FF0000 Go Go Go!!!", getRootElement(), 255, 255, 255, true ) return end outputChatBox ( "#FF0000 ==="..i.."===", getRootElement(), 255, 255, 255, true ) end, 1000, 4 ) setTimer (function() timers[player] = nil end, 30000, 1) end addCommandHandler( "countdown", Countdown ) Client function triggerSound(soundID) sound = playSound( soundID..".mp3", false ) end addEvent ( "triggerclientforGridCountdown", true ) addEventHandler ( "triggerclientforGridCountdown", getRootElement(), triggerSound )
  14. Let us know what you want to achieve. If it's something basic Anyway you've double the thread.
  15. Hey! Im experianced 20 years old IT student. Im collecting money for life and new pc. In free time im programming in different languages and for about 2 and half year scripting for mta. Im a member of DDAS team, basically their scripter. I've done lot of projects in past, starting from small scripts to most advanced user panels based on modified dx-gui resource. You can check some of my scripts on DDAS servers. Website: teamddas.co.uk Anyway if you're looking for a scripter to your project or whatever you have in your mind you can contact me here or via skype: "patryk_gs" Of course remember I can't work for free but im sure we can always figure something out
×
×
  • Create New...