Jump to content

Dx Animations


Mefisto_PL

Recommended Posts

How can I make dxDrawRectangle with animate.. For example in scoreboard is drawing, but I want to move my window from left to right. What events/functions I must use for it? I need an answer and I know that is possible ! :D

///EDIT

Or if it's easier I want to drawing it from left to right, I think it's better way :P

Link to comment
local an_end = 0 
local an_start = 1080/2  -- Depending on screen size 
local an_val = an_start 
  
local posy = 1920/2 
local width = 400 
local height = 400 
  
function openFunc() 
  
if(an_val > an_end) then 
an_val = an_val - 20 
theAnim = dxDrawRectangle(an_val, posy, width, height, tocolor(45,45,45,135), false) 
end 
  
end 
  
addEventHandler("onClientRender", root, openFunc) 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...