Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.

Wysłany: 2013-12-15, 14:08


MrVessu

Uczę się lua :)






Wiek: 26
Na forum: 4574 dni
Posty: 15
Nick w MP: MrVessu



Respekt: 50

Witam. Pom?g? by kto?? Gdy wpisuje /loginpoli , zmienia mi si? kolor nicku, ale pod TAB mnie nie dodaje. Wszystkie inne frakcje dzialaja poprawnie. Zepsu?o si? to po dodaniu frakcji Taxi. Oto m?j kod frakcji:

Kod:

function createTeamsOnStart ()

teamPD = createTeam ( "Pomoc Drogowa", 255, 50, 255 )
teamPogo = createTeam ( "Pogotowie", 255, 255, 0 )
teamUrzad = createTeam ( "Urzad", 100, 100, 100 )
teamTaxi = createTeam ( "Taxi", 255, 300, 0 )
teamPolicja = createTeam ( "Policja", 0, 0, 255 )


end

addEventHandler ( "onResourceStart", getResourceRootElement(getThisResource()), createTeamsOnStart )
function assignteamPD ( player )
setPlayerTeam ( player, teamPD )
spawnPlayer ( player, -1916.0999755859, 267.70001220703, 41 )
setPlayerNametagColor ( player, 255, 50, 255 )
end
addCommandHandler ( "loginpd", assignteamPD )
function assignteamPD ( player )
setPlayerTeam ( player, teamPD )
setPedSkin ( player, 50 )
end
addCommandHandler ( "loginpd", assignteamPD )
PDblip = createBlip ( -1910, 245, 36, 55, 2, 0, 255, 255, 100, 0, 500, getRootElement () )






function assignteamPogo ( player )
setPlayerTeam ( player, teamPogo )
spawnPlayer ( player, -2571, 648, 28 )
setPlayerNameTagColor ( player, 250, 250, 0 )
end
addCommandHandler ( "loginpogo", assignteamPogo )
function assignteamPogo ( player )
setPlayerTeam ( player, teamPogo )
setPedSkin ( player, 275 )
end
addCommandHandler ( "loginpogo", assignteamPogo )
PogoBlip = createBlip ( -2571, 648, 28, 22, 2, 0, 255, 255, 100, 0, 500, getRootElement () )





function assignteamUrzad ( player )
setPlayerTeam ( player, teamUrzad )
spawnPlayer ( player, -1441.5, 846.70001220703, 6.1999998092651 )
setPlayerNametagColor ( player, 100, 100, 100 )
end
addCommandHandler ( "loginu", assignteamUrzad )
function assignteamUrzad ( player )
setPlayerTeam ( player, teamUrzad )
setPedSkin ( player, 111 )
end
addCommandHandler ( "loginu", assignteamUrzad )
UrzadBlip = createBlip ( -1441.5, 846.70001220703, 6.1999998092651, 41, 2, 0, 255, 255, 100, 0, 500, getRootElement () )





function assignteamTaxi ( player )
setPlayerTeam ( player, teamTaxi )
spawnPlayer ( player, -2425.8000488281, 510.29998779297, 29.60000038147 )
setPlayerNametagColor ( player, 255, 300, 0 )
end
addCommandHandler ( "logintaxi", assignteamTaxi )
function assignteamTaxi ( player )
setPlayerTeam ( player, teamTaxi )
setPedSkin ( player, 253 )
end
addCommandHandler ( "logintaxi", assignteamTaxi )
TaxiBlip = createBlip ( -2425.8000488281, 510.29998779297, 29.60000038147, 42, 2, 0, 255, 255, 100, 0, 500, getRootElement () )





function assignteamPolicja ( player )
setPlayerTeam ( player, teamPolicja )
spawnPlayer ( player, -1576, 663, 7 )
setPlayerNametagColor ( player, 0, 0, 255 )
end
addCommandHandler ( "loginpoli", assignteamPolicja )
function assignteamPolicja ( player )
setPlayerTeam ( player, teamPolicja )
setPedSkin ( player, 281 )
end
addCommandHandler ( "loginpoli", assignteamPolicja )
Policjablip = createBlip ( -1576, 663, 7, 30, 2, 0, 255, 255, 100, 0, 500, getRootElement () )


Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-12-15, 15:04


Riot

3X






Wiek: 29
Na forum: 5729 dni
Posty: 1123
Nick w MP: Riot/3X

Piwa: 286

Respekt: 123
Respekt: 123

Spr?buj zamiast

setPlayerTeam playerteamPolicja 


Da?

setPlayerTeam playergetTeamFromName("Policja") ) 


Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-12-15, 15:21


MrVessu

Uczę się lua :)






Wiek: 26
Na forum: 4574 dni
Posty: 15
Nick w MP: MrVessu



Respekt: 50

@Riot Nie dzia?a. Tak jak m?wi?em, po dodaniu Taxi, zrypa?o si?

Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-12-15, 19:09


TheTroll

Pan Majster






Wiek: 38
Na forum: 4764 dni
Posty: 219
Nick w MP: TheTroll

Piwa: 1114

Respekt: 120
Respekt: 120

Wyst?puj? jakie? b??dy w debugscript 3 ? Je?li tak to podaj.

Postaw piwo autorowi tego posta
 

 
Wysłany: 2013-12-16, 10:10


MrVessu

Uczę się lua :)






Wiek: 26
Na forum: 4574 dni
Posty: 15
Nick w MP: MrVessu



Respekt: 50

Dobra, ju? to naprawi?em. Ale chce, ?eby automatycznie po zalogowaniu na serwer przenosi?o na TAB do frakcji

[ Dodano: 2013-12-17, 21:06 ]
Temat mo?na zamkn??. Zrobi?em po prostu Policj? od nowa.

Postaw piwo autorowi tego posta
 

 
Tagi: frakcje
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » LUA Ten temat jest zablokowany bez możliwości zmiany postów lub pisania odpowiedzi

Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Dodaj temat do Ulubionych
Wersja do druku