Lynviy 0 Odesláno: 9. Březen, 2012 Share Odesláno: 9. Březen, 2012 Zdravím, můžu se zeptat jak udělám například na warpech tohle: SendClientMessageToAll(COLOR_ZLUTA, "Hrac XY byl teleportovan do Las Venturas (/lv)."); → Aby místo XY byl nick hráče, jak to udělám? Dále, jak udělám, aby se každé 2 minuty zobrazovalo: "Napište /tele pro zobrazení všech warpů?" Děkuji za rady, Lynviy Link to comment Share on other sites More sharing options...
0 Guest Odesláno: 9. Březen, 2012 Share Odesláno: 9. Březen, 2012 1. přes format(); 2. pohledej timer Link to comment Share on other sites More sharing options...
0 Lynviy 0 Odesláno: 9. Březen, 2012 Author Share Odesláno: 9. Březen, 2012 S tím formatem sem to zkoušel, ale potom, když sem napsal příkaz na odwarpování tak spadl server, takže nevím. Link to comment Share on other sites More sharing options...
0 LYRIcS 88 Odesláno: 9. Březen, 2012 Share Odesláno: 9. Březen, 2012 new string[256], name[24]; GetPlayerName(playerid, name, 24); format(string, sizeof(string), "Hrac %s byl teleportovan do Las Venturas (/lv).", name); SendClientMessageToAll(COLOR_ZLUTA, string); public OnFilterScriptInit() { SetTimer("messages", 120000, 1); return 1; } forward messages(); public messages() { SendClientMessageToAll(, "Napište /tele pro zobrazení všech warpů?"); return 1; } Link to comment Share on other sites More sharing options...
0 Lynviy 0 Odesláno: 9. Březen, 2012 Author Share Odesláno: 9. Březen, 2012 Vím, že sem úplně blbej, že tě otravuju s takovou kravinou.. Ale kam to mám dát? if(strcmp(cmdtext, "/lv", true) == 0) { if(IsPlayerConnected(playerid)) { new car = GetPlayerVehicleID(playerid); if(!IsPlayerInAnyVehicle(playerid)) { SetPlayerPos(playerid,2036.1783,1344.1694,10.5474); SendClientMessageToAll(COLOR_ZLUTA, "Hrac XY byl teleportovan do Las Venturas (/lv)."); SetPlayerInterior(playerid, 0); }else{ SetVehiclePos(car,2036.1783,1344.1694,10.5474); SendClientMessageToAll(COLOR_ZLUTA, "Hrac XY byl teleportovan do Las Venturas (/lv)."); SetPlayerInterior(playerid, 0); } } return 1; } Někam mezi tohle, nebo na začátek? Díky Link to comment Share on other sites More sharing options...
0 LYRIcS 88 Odesláno: 9. Březen, 2012 Share Odesláno: 9. Březen, 2012 if(strcmp(cmdtext, "/lv", true) == 0) { if(IsPlayerConnected(playerid)) { new car = GetPlayerVehicleID(playerid), string[256], name[24]; GetPlayerName(playerid, name, 24); format(string, sizeof(string), "Hrac %s byl teleportovan do Las Venturas (/lv).", name); SendClientMessageToAll(COLOR_ZLUTA, string); if(!IsPlayerInAnyVehicle(playerid)) SetPlayerPos(playerid,2036.1783,1344.1694,10.5474); else SetVehiclePos(car,2036.1783,1344.1694,10.5474); SetPlayerInterior(playerid, 0); } return 1; } Link to comment Share on other sites More sharing options...
0 Lynviy 0 Odesláno: 9. Březen, 2012 Author Share Odesláno: 9. Březen, 2012 Děkuji moc, už mi to funguje . Link to comment Share on other sites More sharing options...
0 Lynviy 0 Odesláno: 10. Březen, 2012 Author Share Odesláno: 10. Březen, 2012 Zdravím, můžete mi prosím pomoct s tímto problémem? #include #define COLOR_FIALOVA 0x800080AA public OnFilterScriptInit() { SetTimer("messages", 180000, 1); return 1; } forward messages(); public messages() { SendClientMessageToAll(COLOR_FIALOVA, "[TIP] Pro opravu auta napište /opravauto."); return 1; } public OnPlayerCommandText(playerid, cmdtext[]) { if (!strcmp("/opravauto", cmdtext)) { RepairVehicle(GetPlayerVehicleID(playerid)); return 1; } } C:\Users\Lynviy\Desktop\repair.pwn(22) : error 017: undefined symbol "RepairVehicle" Děkuji za pomoc, Lynviy Link to comment Share on other sites More sharing options...
0 Petr 44 Odesláno: 10. Březen, 2012 Share Odesláno: 10. Březen, 2012 Máš staré includy. Stáhni si nové s celým SA:MP serverem z http://sa-mp.com Link to comment Share on other sites More sharing options...
0 Lynviy 0 Odesláno: 10. Březen, 2012 Author Share Odesláno: 10. Březen, 2012 Už to de, děkuji moc. Link to comment Share on other sites More sharing options...
0 Lynviy 0 Odesláno: 8. Duben, 2012 Author Share Odesláno: 8. Duben, 2012 Zdravím, vyskytl se mi další problém ohledně warpu. Takhle vypadá jeden warp: if(strcmp(cmdtext, "/lv", true) == 0) { if(IsPlayerConnected(playerid)) { new car = GetPlayerVehicleID(playerid), string[256], name[24]; GetPlayerName(playerid, name, 24); format(string, sizeof(string), "Hráč/ka %s byl/a teleportován/a do Las Venturas (/lv).", name); SendClientMessageToAll(COLOR_ZLUTA, string); if(!IsPlayerInAnyVehicle(playerid)) SetPlayerPos(playerid,2036.1783,1344.1694,10.5474); else SetVehiclePos(car,2036.1783,1344.1694,10.5474); SetPlayerInterior(playerid, 0); } return 1; } A co k tomu musím přidat, aby se hráč nemohl odwarpovat z vězení? (RZE 7.4) Zkoušel jsem něco, co jsem na šel na fóru a nic nefungovalo. Prosím o radu. Děkuji, Lynviy Link to comment Share on other sites More sharing options...
0 LINE UP 0 Odesláno: 8. Duben, 2012 Share Odesláno: 8. Duben, 2012 Podmienku if(IsPlayerConnected(playerid)) ale vôbec nemusíš použiť..načo kontrolovanie či je hráč pripojený ? Veď ak by nebol pripojený tak by nemohol napísať príkaz či nie ? Ak tomu vezeniu...to na rze neviem či spravíš takto..spýtaj sa ATomasa akú dal podmienku na vezenie a podľa toho to rob..alebo si pridaj pri portnutí do vezenia mu nastav premennú na false a potom mu to len skontroluj.. Link to comment Share on other sites More sharing options...
Dotaz
Lynviy 0
Zdravím,
můžu se zeptat jak udělám například na warpech tohle:
SendClientMessageToAll(COLOR_ZLUTA, "Hrac XY byl teleportovan do Las Venturas (/lv)."); → Aby místo XY byl nick hráče, jak to udělám?
Dále, jak udělám, aby se každé 2 minuty zobrazovalo:
"Napište /tele pro zobrazení všech warpů?"
Děkuji za rady,
Lynviy
Link to comment
Share on other sites
11 odpovědí na tuto otázku
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now