Tematy otagowane jako: otwiera
1. brama sie nie otwiera
Brama sie nie otwiera,
server:
[lua]function CDomki()
local object = {}
-- domki do kupna
removeWorldModel(13817, 1000, 1353.23, -625.68, 109.13) --lod
local garazeDayZ = {
jakis = createObject(3095, 1353.66, -626.34, 109.13, -0.0, 0.0, 193.3)
}
object.domki =
{ -- [id] = {x, y, z, preset interioru, cena, wlasciciel(nie zmieniamy z nil), garazID, czas(nie zmieniamy z 0) }
[1] = {2495.23, -1690.42, 13.5, 1, 4000, nil, 9, 0}, -- dom johnsona. grove
[2] = {2523.38, -1658, 14.4, 2, 2350, nil, false, 0}, -- dom po lewej od koszykowki grove
[3] = {2486.5, -1645.8, 13, 3, 3100, nil, false, 0}, -- dom 2-pietrowy grove
[4] = {315.17, -1771, 3.6, 3, 3250, nil, 13, 0}, -- dom na plazy 2-pietrowy garaz
[5] = {1298.69, -800.46, 83, 4, 10000, nil, false, 0}, -- willa madd doga
[6] = {2468.79, -1295.53, 28.9, 2, 2200, nil, false, 0}, -- dom jednorodzinny kolo strip clubu
[7] = {2068.12, -1731.63, 12.8, 6, 2000, nil, false, 0}, -- kolo pizzerii
[8] = {2069, -1717, 12.5, 6, 2000, nil, false, 0}, -- kolo domku wyzej
[9] = {1981.72, -1682.74, 16, 3, 3300, nil, false, 0}, -- domek 2 pi?trowy ko?o domk?w wy?ej
[10] = {1981.47, -1718.94, 16, 3, 3250, nil, false, 0}, -- domek 2 pi?trowy kolejny obok tego wy?ej
[11] = {1331.41, -631.56, 108.13, 5, 4000, nil, garazeDayZ.jakis, 0}, -- domek mulholland
[12] = {1686, -2100, 12.8, 7, 3000, nil, 5, 0}, -- domek el corona
[13] = {2382.98, -1366.29, 23.4, 6, 2100, nil, false, 0}, -- syfia...
2. Z poziomu pasażera otwiera mi się gui tankowania
Hej
Jak kto? podje?d?a na stacj?, a jestem pasa?erem to widz? gui i moge tankowa?
jak to zablokowa??
3. nie otwiera gui i nie pokazuje blipa
Witam mam pewien problem robi? sobie gui lecz jest problem one w og?le si? nie otwiera
[lua]
marker = {
{369.75, -2043.86, 7.67},
{848.63, -1822.13, 12.19},
{-1567.03, -2735.30, 48.54},
{-2328.49, -1618.51, 483.71},
{-1945.10, -1084.70, 30.78},
{-2524.29, -604.01, 132.56},
{-2793.32, -380.37, 7.04},
{-2354.25, -154.45, 35.32},
{-2769.76, 229.40, 7.06},
{-2208.21, 639.76, 49.44},
{-1790.54, 1428.62, 7.19},
{-2512.31, 1205.41, 37.42},
{-2261.07, 2287.73, 4.82},
{-1267.02, 2708.03, 50.07},
{-926.00, 2026.48, 60.91},
{-366.77, 1129.84, 19.76},
{2144.14, 2808.86, 10.82},
{2444.98, 2290.26, 10.82},
{1722.32, 2105.34, 10.82},
{2206.28, 1514.67, 10.82},
{2461.04, 1158.96, 10.82},
{1542.48, 1033.90, 10.82},
{1098.74, 1450.08, 12.55},
{1500.63, 773.24, 10.82},
{1288.60, 342.65, 19.55},
{1925.90, 174.90, 37.28},
}
GUIEditor = {
gridlist = {},
window = {},
button = {}
}
addEventHandler("onClientResourceStart", resourceRoot,
function()
GUIEditor.window[1] = guiCreateWindow(424, 275, 888, 475, "Towary", false)
guiWindowSetSizable(GUIEditor.window[1], false)
GUIEditor.gridlist[1] = guiCreateGridList(10, 20, 855, 341, false, GUIEditor.window[1])
guiGridListAddColumn(GUIEditor.gridlist[1], "#", 0.2)
guiGridListAddColumn(GUIEditor.gridlist[1], "Nazwa Towaru", 0.2)
guiGridListAddColumn(GUIEditor.gridlist[1], "Wyn...
4. Gui otwiera się każdemu graczowi
Gui otwiera si? ka?demu graczowi a nie tylko temu co wejdzie w marker
funkcja na pokazanie si? gui po wej?ciu w marke
function panel_otworz ()
tick = getTickCount ()
font = dxCreateFont ( "png/sans-pro-regular.ttf" , 20 )
font2 = dxCreateFont ( "png/Dosis-Bold.ttf" , 20 )
showCursor ( true )
addEventHandler ( "onClientRender" , root , panel_prawka )
addEventHandler ( "onClientClick" , root , onClientClick )
end
addEventHandler ( "onClientMarkerHit" , rozpoczecie_marker , panel_otworz )
5. Zawsze otwiera się OSTATNIA BRAMKA W TABELI :(
Witam,
Tak jak w tutyle, a mianowicie pr?buj? zrobi? tabel? z obiektami, kt?re si? otwieraj? lecz ZAWSZE, ALE TO ZAWSZE otwiera si? ostatni obiekt w tabeli.
local marker_test = createMarker ( 1786.9000244141 , 2337.5 , 5.5 , "cylinder" , 2.5 , 0 , 0 , 0 , 75 )
local blokady = {
{ 1251 , 1792.5999755859 , 2328.3999023438 , 5.5 , 0 , 0 , 0 },
{ 1251 , 1790.6999511719 , 2328.3999023438 , 5.5 , 0 , 0 , 0 },
}
for k , v in pairs ( blokady ) do
local blokada = createObject ( v [ 1 ], v [ 2 ], v [ 3 ], v [ 4 ], v [ 5 ], v [ 6 ], v [ 6 ])
function brama_otworz_test ( thePlayer )
if isElementWithinMarker ( thePlayer , marker_test ) then
moveObject ( blokada , 500 , v [ 2 ], v [ 3 ], 6 )
end
end
function brama_zamknij_test ( thePlayer )
if isElementWithinMarker ( thePlayer , marker_test ) then
moveObject ( blokada , 3000 , v [ 2 ], v [ 3 ], v [ 4 ])
end
end
end
META
Kod: <meta>
<script src="test.lua" type="server" />
</meta>
bindKey'e mam zrobione.
6. Gui otwiera sie wszystkim graczą (ma tylko 1)
Tak jak u g?ry. oczywi?cie ma sie pojawic tej osobie co wjedzie w marker)
Prosi?bym o kr?tkie wyt?umaczenie jak ktos napisze, ?ebym wiedzia? na przysz?o?? jak robi?.
function wylaczoknopraca ( thePlayer )
if source == wroc then
guiSetVisible ( okno , false )
guiSetVisible ( memo , false )
guiSetVisible ( zatrudnij , false )
guiSetVisible ( zwolnij , false )
guiSetVisible ( wroc , false )
showCursor ( false )
end
end
7. Panel nie otwiera się
[lua]
GUIEditor = {
gridlist = {},
window = {},
button = {}
}
addEventHandler("onClientResourceStart", resourceRoot,
function()
GUIEditor.window[1] = guiCreateWindow(460, 205, 391, 298, "Panel Pomocy Drogowej v1.0", false)
guiWindowSetSizable(GUIEditor.window[1], false)
guiSetProperty(GUIEditor.window[1], "CaptionColour", "FFE802C5")
GUIEditor.button[1] = guiCreateButton(13, 37, 116, 51, "Napraw", false, GUIEditor.window[1])
GUIEditor.button[2] = guiCreateButton(13, 120, 116, 51, "Tankuj", false, GUIEditor.window[1])
GUIEditor.button[3] = guiCreateButton(13, 215, 116, 51, "Napraw i Tankuj", false, GUIEditor.window[1])
GUIEditor.gridlist[1] = guiCreateGridList(206, 42, 176, 230, false, GUIEditor.window[1])
guiGridListAddColumn(GUIEditor.gridlist[1], "Lista graczy", 0.9)
GUIEditor.button[4] = guiCreateButton(366, 21, 16, 16, "X", false, GUIEditor.window[1])
end
)
addEventHandler("onClientRender", root,
function()
dxDrawLine(633, 349, 635, 355, tocolor(255, 255, 255, 255), 1, false)
end
)
function openPanel()
guiSetVisible(GUIEditor.window[1], true)
showCursor(true)
end
addCommandHandler("panelpd", openPanel)
function zamykamy()
if source =~ GUIEditor.button[4] then
guiSetVisible(GUIEditor.window[1],false)
showCursor(false)
end
end
addEventHandler("onClientGUIClick", root, zamykamy)
function na...
8. Brama nie otwiera się
Witam,mam do was pytanie dlaczego po wpisaniu /bramagoh wyskakuje komunikat "Nie nale?ysz do gangu Gang Of Hooligans"
GD_GANG = "Gang Of Hooligans"
GD_BRAMA = false
-------------------- BRAMA ----------------------------
brama = createObject ( 980 , 320.39999389648 ,- 1189 , 78.099998474121 , 0 , 0 , 40 )
addCommandHandler ( "bramagoh" , function ( p , c )
if getElementData ( p , "gang" ) ~= GD_GANG then
outputChatBox ( "Nie nale?ysz do Gangu " .. GD_GANG .. " " , p )
return false
end
if GD_BRAMA == true then
GD_BRAMA = false
moveObject ( brama , 1000 , 320.39999389648 ,- 1189 , 78.099998474121 )
outputChatBox ( "Brama wjazdu zamkni?ta !" , p )
else
GD_BRAMA = true
moveObject ( brama , 1000 , 308.29998779297 ,- 1197.5 , 78.099998474121 ) -- kordy bramy ( szybkosc otwierania w ms , x , y , z ) , tutaj podajemy kordy bramy otwartej
outputChatBox ( "Brama wjazdu otwarta !" , p ) -- tekst po wpisaniu komendy
end
end )
Gdy wpisuje komende na otwarcie /bramagoh i ju? mam na localu zrobiony team Gang Of Hooligans,i gdy wpisa?em wyskakuje "Nie nale?ysz do gangu Gang Of Hooligans" dlaczego? prosz? o poprawienie tego kodu
9. Potocy okno sie nie otwiera
witam tak jak w temacie o co chodzi ?
[lua]
GUIEditor = {
tab = {},
tabpanel = {},
label = {},
button = {},
window = {}
}
addEventHandler("onClientResourceStart", resourceRoot,
function()
GUIEditor.window[1] = guiCreateWindow(519, 290, 961, 209, "Panel Pojazdu", false)
guiWindowSetSizable(GUIEditor.window[1], false)
GUIEditor.button[1] = guiCreateButton(14, 37, 175, 45, "Silnik", false, GUIEditor.window[1])
GUIEditor.button[2] = guiCreateButton(199, 37, 175, 45, "?wiat?a", false, GUIEditor.window[1])
GUIEditor.button[3] = guiCreateButton(776, 154, 175, 45, "Zniszcz Pojazd", false, GUIEditor.window[1])
GUIEditor.tabpanel[1] = guiCreateTabPanel(727, 25, 214, 80, false, GUIEditor.window[1])
GUIEditor.tab[1] = guiCreateTab("Zniszcz Pojazd", GUIEditor.tabpanel[1])
GUIEditor.label[1] = guiCreateLabel(5, 5, 199, 40, "Zniszcz Pojazd (chwilowo nie dzia?a)", false, GUIEditor.tab[1])
guiLabelSetHorizontalAlign(GUIEditor.label[1], "left", true)
GUIEditor.window[2] = guiCreateWindow(519, 290, 961, 209, "Panel Pojazdu", false)
guiWindowSetSizable(GUIEditor.window[2], false)
end
)
function Lights ( player )
car = getPedOccupiedVehicle ( player )
if ( car ) then
if not vehicleLights[ car ] then
setVehicleOverrideLights ( car, 2 )
outputChat...
10. [INNE] Po kliknieciu na gracza z TAB otwiera się gui
Wie kto? jak zrobi? ze wybeiram gracza z TAB i pokazuje mi si? gui