GTA Közösség - A magyar GTA fórum

Multi Theft Auto (MTA) => MTA: Szerverfejlesztés => Archívum => A témát indította: Juhander - 2014. Augusztus 13. - 10:48:10

Cím: Telefon script probléma
Írta: Juhander - 2014. Augusztus 13. - 10:48:10
Hali. Csináltam egy telefon scriptet viszont azthiszem mindent jól megirtam ,de nem ugrik elő sehogyse a mobil.
Script.lua
 

function telefon1 ()
screenwidth, screenHeight = guiGetScreenSize
WindowWidth, windowleight = 390, 707
x = (screenWidth/2) - (windowWidth/2)
y = (screenHeight/2) - (windowHeight/2)
telefon = guiCreateStaticImage (x, y, 390, 707, \"phone_main.png\", false)
end
addCommandHandler (\"telefon1\", telefon1)
 
[/quote]
Meta.xml
 

<meta>
<info author=\"juhander\" version=\"1.0\" type=\"script\"/>
<script src=\"script.lua\" type=\"client\"/>
<file src=\"phone_main.png\" type=\"client\"/>
</meta>
 
[/quote]
Kezdő scripter vagyok szóval :D úgy nézzetek rám
Cím: Telefon script probléma
Írta: Toxic - 2014. Augusztus 13. - 10:52:33

function telefon1 ()
screenwidth, screenHeight = guiGetScreenSize
WindowWidth, windowleight = 390, 707
x = (screenWidth/2) - (windowWidth/2)
y = (screenHeight/2) - (windowHeight/2)
telefon = guiCreateStaticImage (x, y, 390, 707, \"phone_main.png\", false)
end
addCommandHandler (\"telefon1\", telefon1)
 
[/quote]
Edit: pirossal bejelöltem neked a hibákat :D
Cím: Telefon script probléma
Írta: Juhander - 2014. Augusztus 13. - 10:55:37
őő látom ,hogy kihúztad pirossal ,de semmi különbséget nemlátok xd
Cím: Telefon script probléma
Írta: Toxic - 2014. Augusztus 13. - 10:57:58
Rossz:
 

screenwidth, screenHeight = guiGetScreenSize
   WindowWidth, windowleight = 390, 707
[/quote]
Jó:
 

screenWidth, screenHeight = guiGetScreenSize()
   windowWidth, windowHeight = 390, 707
[/quote]
Szerintem így már észreveszed :D
Edit: találtam még 1 \"elírást\"
Edit2: találtam még 1 \"elírást\" xD
Cím: Telefon script probléma
Írta: Juhander - 2014. Augusztus 13. - 11:01:49
átjavitottam ,de sajnos igy se megy. Elinditom ,de a /telefon1 -el nem dobja ki :(

Dupla üzenet összevonva ekkor: 2014. Augusztus 13. - 21:47:40


function telefon1 ()
screenWidth, screenHeight = guiGetScreenSize ()
windowWidth, windowHeight = 300, 400
x = (screenWidth/2) - (windowWidth/2)
y = (screenHeight/2) - (windowHeight/2)
hatter = guiCreateStaticImage (x, y, 260, 471, \"phone_main.png\", false)
showCursor(true)
gomb1 = guiCreateLabel(93, 237, 34, 34, \"AAAAAA\", false, hatter)
addEventHandler(\"onClientGuiClick\", gomb1, gombteszt, false)
end
addCommandHandler (\"telefon1\", telefon1)
function gombteszt()
outputChatBox ( \"Sikeresen elinditottad a Flappy Bird-ot\" )
end
 
[/quote]
Na most az van ,hogy elindul ,de ez a mondat nem urgik ki amikor rámegyek az \"AAAA\"-ra
Cím: Telefon script probléma
Írta: Enigma - 2014. Augusztus 13. - 22:10:06
Egyszerűbb lenne ha használnád a /debugscript 3 parancsot, és megosztanád velünk milyen errort kapsz.
Cím: Telefon script probléma
Írta: Juhander - 2014. Augusztus 14. - 12:52:21
Beirtam ,hogy /debugscript 3 viszont semmit nem dob ki az ég világon. mondjuk azt se tudom ,hol kellene valamit kidobnia :D
Cím: Telefon script probléma
Írta: Toxic - 2014. Augusztus 24. - 00:16:15
[mod]Elavult, zárom.[/mod]