Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.
GTAONLINE.PL
Tematy otagowane jako: guigetscreensize
1. jak naprawic guiGetScreenSize
Kod:

local x, y = guiGetScreenSize()
local w, h = (x/1280), (y/1024)
renderr = false
function dxDrawGUI()
-- Zmienny tekst
if getElementData(localPlayer, "praca:magazynier") == true then
ZmianTekst = "Zako?cz Prace"
else
ZmianTekst = "Rozpocznij Prace"

2. guiGetScreenSize
Cze??
Mam taki kod
local screenWscreenH guiGetScreenSize()

local marker1 createMarker(-282.491080.9319.74-1,"cylinder",1.5,255,255,215,1)

addEventHandler("onMarkerHit"marker1, function(el,md)
dxDrawImage(screenW 0screenH 0screenW 1screenH 1"Pies.png"000tocolor(255255255255), false)
setElementFrozen(eltrue)
    
setElementInterior(el,0)
    
setElementDimension(el,0)
    
setElementPosition(el,-320.651062.6919.74)


W db3 pokazuje mi si? co? takiego
Kod:

attempt to call global 'guiGetScreenSize'(a nil value)


Pomo?e kto? rozwi?za? ten problem
Dzi?ki !
3. guiGetScreenSize
Witam, tak jak w temacie, poszukuj? poradnika na temat funkcji guiGetScreenSize.

W ci?gu kilku ostatnich dni stworzy?em panel Logowania na m?j serwer, ale lua si? ucz? od kilku tygodni, wi?c nie ogarniam jeszcze tej funkcji.


local winlogin = guiCreateWindow(0,0,550,780,"Logowanie",false) -- okno logowania
local zaloguj = guiCreateButton(40,625,220,100,"Zaloguj",false,winlogin)
local zarejstruj = guiCreateButton(295,625,220,100,"Rejstracja",false,winlogin)

Chcia?bym, aby kto? mi wyt?umaczy?, jak poda? te wszystkie rozdzielczo?ci, ?eby elementy w oknie si? nie "rozje?d?a?y" po zmianie rozdzielczo?ci na mniejsz?.

Za wszelk? pomoc serdecznie dzi?kuj? :)

Pozdrawiam

[ Komentarz dodany przez: Iggy: 2015-11-18, 19:24 ]
Usun??em z nazwy tematu ,,[Poszukuj? Poradnika] "//Iggy.
4. guiGetScreenSize
attempt to call global 'guiGetScreenSize' (a nil value), nie wiem o co chodzi. Mo?ecie wyja?ni??
5. guiGetScreenSize
Jak dopasowac to okno do kazdej rozdzielczosci?

[lua]
GUIEditor = {
gridlist = {},
button = {},
edit = {}
}

GUIEditor.gridlist[1] = guiCreateGridList(241, 98, 1101, 691, false)
guiSetAlpha(GUIEditor.gridlist[1], 0.79)
GUIEditor.edit[1] = guiCreateEdit(109, 229, 313, 39, "", false, GUIEditor.gridlist[1])
GUIEditor.edit[2] = guiCreateEdit(109, 429, 313, 39, "", false, GUIEditor.gridlist[1])
GUIEditor.button[1] = guiCreateButton(33, 555, 468, 55, "LOGUJ NA POSTA?", false, GUIEditor.gridlist[1])
guiSetFont(GUIEditor.button[1], "clear-normal")
guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FFAAAAAA")
GUIEditor.edit[3] = guiCreateEdit(646, 229, 313, 39, "", false, GUIEditor.gridlist[1])
GUIEditor.edit[4] = guiCreateEdit(646, 429, 313, 39, "", false, GUIEditor.gridlist[1])
GUIEditor.button[2] = guiCreateButton(590, 555, 468, 55, "REJESTRUJ POSTA?", false, GUIEditor.gridlist[1])
guiSetFont(GUIEditor.button[2], "clear-normal")
guiSetProperty(GUIEditor.button[2], "NormalTextColour", "FFAAAAAA")

function draw()
dxDrawLine(787, 98, 787, 788, tocolor(255, 255, 255, 255), 1, true)
dxDrawText("Logowanie", 340, 115, 773, 220, tocolor(0, 0, 0, 255), 2.00, "bankgothic", "left", "...
6. guiGetScreenSize
Witam
Jak zrobi? dxText ?eby by? na g?rze za pomoc? tej funkcji.
?eby by? widoczny w tym samym miejscu na rozdzielczo?ci 800x600 i 1240x720
Pozdrawiam
Dzi?kuje za Pomoc.
I ?ycze Weso?ych ?wi?t