local rX, rY = guiGetScreenSize() -- حجم الشاشة
function RelativeToAbsolute( X, Y ) -- وظيفة تعديل احداثيات الدي اكس لجميع الشاشات #
local x = X*rX
local y = Y*rY
return x, y
end
addEventHandler("onClientRender",root, -- اضافة حدث الرندر
function ( ) -- انشاء وظيفة
local CurrentTime = getRealTime() -- نجيب الوقت الحقيقي كآملآ بـ الجدول !!
local Hours = CurrentTime.hour -- هنا نجيب الوقت الحقيقي من الساعات
local Minute = CurrentTime.minute -- الوقت الحقيقي من الدقائق
local Secounds = CurrentTime.second -- الوقت الحقيقي من الثواني
local xs,ys = RelativeToAbsolute ( 0.28, 0.23 )
dxDrawText("The Current Time is : "..Hours.." : "..Minute.." : "..Secounds.." ",xs,ys,rX,rY, tocolor(255,150, 0, 255),4, "arial", "center", "center", false, false, true, false, false) -- نرسم الجدول على الشاشة
end -- اغلاق
) -- اغلاق