Du hast nur gesagt das man nicht den Namen what ever sieht
Aber um ihn zusehen machst du
PlayerSpectatePlayer(playerid,pID);
Du hast nur gesagt das man nicht den Namen what ever sieht
Aber um ihn zusehen machst du
PlayerSpectatePlayer(playerid,pID);
format(string,sizeof(string),"%s\nLeben: %f\nArmour: %f\nGeld: %d",SpielerName(pID),GetPlayerHealth(pID),GetPlayerArmour(pID),GetPlayerMoney(pID));
stock SpielerName(playerid)
{
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
return name;
}
Hey,
Ab wann wird das Cloud Scripting drin sein?
Weil mich das grade sehr an diesem Programm interessiert
if(dialogid == DIALOG_Werbung)
{
if(response)
{
if(strlen (inputtext) >= 75)
{
SendClientMessage(playerid,WEISS,"Du hast zuviele Zeichen Benutzt");
}
else
{
new string[124];
new payout = strlen(inputtext) * SBizzInfo[7][sbEntranceCost];
if(GetPlayerMoney(playerid) < payout)
{
format(string, sizeof(string), "* Du hast %d Zeichen benutzt, das kostet $%d, du hast nicht genug dabei.", inputtext, payout);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
return 1;
}
GivePlayerMoney(playerid, - payout);
SBizzInfo[7][sbTill] += payout/2;
ExtortionSBiz(5, payout);
format(string, sizeof(string), "[Werbung]: %s, Kontakt: %s, Handynr.: %d",inputtext , SpielerName(playerid),PlayerInfo[playerid][pPnumber]);
SendClientMessageToAll(GRÜN,string);
format(string, sizeof(string), "~r~Rechnung: $%d~n~~w~Nachricht hatte: %d Zeichen.", payout, inputtext);
GameTextForPlayer(playerid, string, 5000, 5);
}
}
}
Ich gebe nur Hey ein und es kommt das ich 72 Zeichen gemacht habe
Und die werbung ist umsonst
Okay,
Danke
Wie berechene ich nun wieviele Buchstaben es sind und was es kostet?
if(dialogid == DIALOG_Werbung)
{
if(response)
{
if(strlen (inputtext) >= 75)
{
SendClientMessage(playerid,WEISS,"Du hast zuviele Zeichen Benutzt");
}
else
{
new string[124];
new payout = strlen (inputtext) * SBizzInfo[7][sbEntranceCost];
if(GetPlayerMoney(playerid) < payout)
{
format(string, sizeof(string), "* Du hast %d Zeichen benutzt, das kostet $%d, du hast nicht genug dabei.", strlen (inputtext), payout);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
return 1;
}
GivePlayerMoney(playerid, - payout);
SBizzInfo[7][sbTill] += payout/2;
ExtortionSBiz(5, payout);
format(string, sizeof(string), "[Werbung]: %s, Kontakt: %s, Handynr.: %d",strlen (inputtext) , SpielerName(playerid),PlayerInfo[playerid][pPnumber]);
SendClientMessageToAll(GRÜN,string);
format(string, sizeof(string), "~r~Rechnung: $%d~n~~w~Nachricht hatte: %d Zeichen.", payout, strval(inputtext));
GameTextForPlayer(playerid, string, 5000, 5);
}
}
}
Geht immer noch ned
Hey,
Ich möchte das man seine Werbung in einem Dialog eingibt
Und es damm im Text erscheint nur bei mir kommt einfach kein Text
Woran kann das Liegen??
if(dialogid == DIALOG_Werbung)
{
if(response)
{
if(strval(inputtext) >= 75)
{
SendClientMessage(playerid,WEISS,"Du hast zuviele Zeichen Benutzt");
}
else
{
new string[124];
new payout = strval(inputtext) * SBizzInfo[7][sbEntranceCost];
if(GetPlayerMoney(playerid) < payout)
{
format(string, sizeof(string), "* Du hast %d Zeichen benutzt, das kostet $%d, du hast nicht genug dabei.", strval(inputtext), payout);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
return 1;
}
GivePlayerMoney(playerid, - payout);
SBizzInfo[7][sbTill] += payout/2;
ExtortionSBiz(5, payout);
format(string, sizeof(string), "[Werbung]: %s, Kontakt: %s, Handynr.: %d",strval(inputtext) , SpielerName(playerid),PlayerInfo[playerid][pPnumber]);
SendClientMessageToAll(GRÜN,string);
format(string, sizeof(string), "~r~Rechnung: $%d~n~~w~Nachricht hatte: %d Zeichen.", payout, strval(inputtext));
GameTextForPlayer(playerid, string, 5000, 5);
}
}
}
So hatte ich es so ging es auch nicht
Weshalb ich das isplayerinfrac gemacht hab
Hey,
kann man vielleicht den Forum Link im ersten Post rein tun
Da ich die Seite einfach nicht finde
Nicht mal durch google
Mein Problem ist das nur LEADER
Sehen in welcher Fraktion sie sind
Member sehen immer Zivilist
Ist nicht nur bei SWAT
stock IsPlayerInFrac(playerid,fracid)
{
if (PlayerInfo[playerid][pMember] == fracid || PlayerInfo[playerid][pLeader] == fracid)
{
return 1;
}
return 0;
}
Hey,
Wenn man in der Fraktions ID 22 ist wird einem bei den /stats Zivilist gezeigt
Nur ich finde den Fehler einfach nicht
Vielleicht findet ihr ihn ja wäre aufjeden fall echt geil
Function Stats(playerid,targetid)
{
if(IsPlayerConnected(targetid))
{
new cash = GetPlayerMoney(targetid);
new atext[20];
if(PlayerInfo[targetid][pSex] == 1) { atext = "Männlich"; }
else if(PlayerInfo[targetid][pSex] == 2) { atext = "Weiblich"; }
new otext[20];
if(PlayerInfo[targetid][pOrigin] == 1) { otext = "Deutschland"; }
else if(PlayerInfo[targetid][pOrigin] == 2) { otext = "Osterreich"; }
else if(PlayerInfo[targetid][pOrigin] == 3) { otext = "Schweiz"; }
else if(PlayerInfo[targetid][pOrigin] == 4) { otext = "Türkei"; }
new ttext[20];
new dtext[20];
if(STDPlayer[targetid] == 1) { dtext = "Chlamydia"; }
else if(STDPlayer[targetid] == 2) { dtext = "Gonorrhea"; }
else if(STDPlayer[targetid] == 3) { dtext = "Syphilis"; }
else { dtext = "Keine"; }
if(IsPlayerInFrac(targetid,0))//Zivilist
{
ttext = "Zivilist";
}
else if(IsPlayerInFrac(targetid,1))//PD Ranks
{
ttext = "SFPD";
}
else if(IsPlayerInFrac(targetid,2))//FBI Ranks
{
ttext = "FBI";
}
else if(IsPlayerInFrac(targetid,3))//ARMY
{
ttext = "ARMY";
}
else if(IsPlayerInFrac(targetid,4))//Medic
{
ttext = "Medic";
}
else if(IsPlayerInFrac(targetid,5))//LCN
{
ttext = "La Cosa Nostra";
}
else if(IsPlayerInFrac(targetid,6))//Yakuza
{
ttext = "Yakuza";
}
else if(IsPlayerInFrac(targetid,7))//Regierung
{
ttext = "Regierung";
}
else if(IsPlayerInFrac(targetid,8))//Hitman
{
ttext = "Hitman";
}
else if(IsPlayerInFrac(targetid,9))//SN
{
ttext = "San News";
}
else if(IsPlayerInFrac(targetid,10))//Taxi
{
ttext = "Taxi";
}
else if(IsPlayerInFrac(targetid,11))//Fahrschule
{
ttext = "Fahrschule";
}
else if(IsPlayerInFrac(targetid,13))//Grove Street
{
ttext = "Grove Street";
}
else if(IsPlayerInFrac(targetid,14))//Ballas
{
ttext = "Ballas";
}
else if(IsPlayerInFrac(targetid,15))//Hells Angel
{
ttext = "Hells Angel";
}
else if(IsPlayerInFrac(targetid,17))//La Aztecas
{
ttext = "La Aztecas";
}
else if(IsPlayerInFrac(targetid,20))//Terror
{
ttext = "Terror";
}
else if(IsPlayerInFrac(targetid,21))//Wheelman
{
ttext = "Wheelman";
}
else if(IsPlayerInFrac(targetid,22))//SWAT
{
ttext = "SWAT";
}
else if(IsPlayerInFrac(targetid,23))//ADAC
{
ttext = "ADAC";
}
new rtext[64];
if(IsPlayerInFrac(targetid,0))//Zivilist
{
if(PlayerInfo[targetid][pRank] == 0) { rtext = "Zivilist"; }
}
else if(IsPlayerInFrac(targetid,1))//PD Ranks
{
if(PlayerInfo[targetid][pRank] == 13) { rtext = "Leitender Polizeidirektor"; }
else if(PlayerInfo[targetid][pRank] == 12) { rtext = "Polizeidirektor"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "Polizeioberrat"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "Polizeirat"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Erster Polizeihauptkommissar"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Polizeihauptkommissar"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Polizeioberkommissar"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Polizeikommissar"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Polizeihauptmeister"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Polizeiobermeister"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Polizeimeister"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Polizeikommissaranwärter"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Polizeimeisteranwärter"; }
}
else if(IsPlayerInFrac(targetid,2))//FBI Ranks
{
if(PlayerInfo[targetid][pRank] == 10) { rtext = "Director"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Deputy Director"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Assistent Director"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Special Agent in Charge"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Assistent Special Agent in Charge"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Supervisory Special Agent"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Special Agent"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "New Agent"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Azubi"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Praktikant"; }
}
else if(IsPlayerInFrac(targetid,3))//ARMY
{
if(PlayerInfo[targetid][pRank] == 13) { rtext = "General"; }
else if(PlayerInfo[targetid][pRank] == 12) { rtext = "General Major"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "Oberst"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "Major"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Oberleutnant"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Leutnant"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Oberstabsfeldwebel"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Feldwebel"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Oberoffizier"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Stabsunteroffizier"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Unteroffizier"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Obergefreiter"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Gefreiter"; }
}
else if(IsPlayerInFrac(targetid,7))
{
if(PlayerInfo[targetid][pRank] == 12) { rtext = "Bundespräsident"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "Bundeskanzler"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "Staatsminister"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Finanz-Minister"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Steuer-Minister"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Minister"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Geheimdienst-Leiter "; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Geheimdienst"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Geheimdienst-Azubi"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Personenschutz-Leiter"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Personenschutz"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Personenschutz-Azubi"; }
}
else if(IsPlayerInFrac(targetid,8))//Hitman Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Neuling"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Killer"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Profi Killer"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Schütze"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Vice Director"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director"; }
}
else if(IsPlayerInFrac(targetid,9))//SN Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Intern"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Lokaler Reporter"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Lokaler Bearbeiter"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Netzwerk Manager"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Netzwerk Bearbeiter"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Netzwerk Hersteller"; }
else { rtext = "Intern"; }
}
else if(IsPlayerInFrac(targetid,10))//Taxi Company Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Taxi Fahrer Azubi"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Taxi Neuling"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Taxi Fahrer"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Zuteiler"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Schichtzuteiler"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Taxi Firmen Besitzer"; }
else { rtext = "Trainee"; }
}
else if(IsPlayerInFrac(targetid,11))//Driving/Flying School Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Praktikant"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Azubi"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Fahrlehrer"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Manager"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co Boss"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
}
else if(IsPlayerInFrac(targetid,13))//GS
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co-Boss"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Gangster"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Homie"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Bro"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Sidekick"; }
}
else if(IsPlayerInFrac(targetid,14))//ballas
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co-Boss"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Gangster"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Homie"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Bro"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Sidekick"; }
}
else if(IsPlayerInFrac(targetid,15))//hells
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Anführer"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Stell. Anführer"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Gruftie"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Rüpel"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Rowdy"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Grossfahrer"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Rollerfahrer"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Fahrradfahrer"; }
}
else if(IsPlayerInFrac(targetid,17))//LA
{
if(PlayerInfo[playerid][pRank] == 6) { rtext = "President"; }
else if(PlayerInfo[playerid][pRank] == 5) { rtext = "Co-President"; }
else if(PlayerInfo[playerid][pRank] == 4) { rtext = "Bandito"; }
else if(PlayerInfo[playerid][pRank] == 3) { rtext = "Cazador"; }
else if(PlayerInfo[playerid][pRank] == 2) { rtext = "Compadre"; }
else if(PlayerInfo[playerid][pRank] == 1) { rtext = "Amigo"; }
}
else if(IsPlayerInFrac(targetid,20))//Terror
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co-Boss"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Terrorist"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Attentäter"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Auszubildender Attentäter"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Terrorzwerg"; }
}
else if(IsPlayerInFrac(targetid,21))//wheelman
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Anfänger"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Söldner"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Special Söldner"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Ausbilder"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co Direktor"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Direktor"; }
}
else if(IsPlayerInFrac(targetid,22))//SWAT
{
if(PlayerInfo[targetid][pRank] == 12) { rtext = "SWAT-General"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "SWAT-Major-General"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "SWAT-Major"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "SWAT-Lieutenant"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "SWAT-Sergeant"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "SWAT-Investigator"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "SWAT-Inspector"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "SWAT-Detective"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "SWAT-Corporal"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "SWAT-Officer"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "SWAT-Trooper"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "SWAT-Greenhorn"; }
}
else if(IsPlayerInFrac(targetid,24))
{
if(PlayerInfo[targetid][pRank] == 9) { rtext = "Filialleiter"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Vorarbeiter"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Ausbilder"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Abschlepper 3"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Abschlepper 2"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Abschlepper 1"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Service Fahrer"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Azubi"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Praktikant"; }
}
new jtext[20];
if(PlayerInfo[targetid][pJob] == 0) { jtext = "Keinen"; }
else if(PlayerInfo[targetid][pJob] == 1) { jtext = "Detektiv"; }
else if(PlayerInfo[targetid][pJob] == 2) { jtext = "Anwalt"; }
else if(PlayerInfo[targetid][pJob] == 3) { jtext = "Hure"; }
else if(PlayerInfo[targetid][pJob] == 4) { jtext = "Drogendealer"; }
else if(PlayerInfo[targetid][pJob] == 5) { jtext = "Autodieb"; }
else if(PlayerInfo[targetid][pJob] == 6) { jtext = "Farmer"; }
else if(PlayerInfo[targetid][pJob] == 7) { jtext = "Mechaniker"; }
else if(PlayerInfo[targetid][pJob] == 8) { jtext = "Bodyguard"; }
else if(PlayerInfo[targetid][pJob] == 9) { jtext = "Waffendealer"; }
else if(PlayerInfo[targetid][pJob] == 10) { jtext = "Autohändler"; }
else if(PlayerInfo[targetid][pJob] == 12) { jtext = "Boxer"; }
else if(PlayerInfo[targetid][pJob] == 14) { jtext = "Busfahrer"; }
else if(PlayerInfo[targetid][pJob] == 15) { jtext = "Zeitungsjunge"; }
else if(PlayerInfo[targetid][pJob] == 16) { jtext = "Pilot"; }
else if(PlayerInfo[targetid][pJob] == 17) { jtext = "Müllmann"; }
else if(PlayerInfo[targetid][pJob] == 20) { jtext = "Hartz IV"; }
else if(PlayerInfo[targetid][pJob] == 21) { jtext = "Taschendieb"; }
else { jtext = "Keinen Job"; }
new drank[20];
if(PlayerInfo[targetid][pDonateRank] == 0) { drank = "Keinen"; }
else if(PlayerInfo[targetid][pDonateRank] == 1) { drank = "EhrenMember"; }
else { drank = "Keinen"; }
new married[20];
strmid(married, PlayerInfo[targetid][pMarriedTo], 0, strlen(PlayerInfo[targetid][pMarriedTo]), 255);
new age = PlayerInfo[targetid][pAge];
// new ptime = PlayerInfo[targetid][pConnectTime];
// new lotto = PlayerInfo[targetid][pLottoNr];
new deaths = PlayerInfo[targetid][pDeaths];
// new fishes = PlayerInfo[targetid][pFishes];
// new bigfish = PlayerInfo[targetid][pBiggestFish];
// new crimes = PlayerInfo[targetid][pCrimes];
// new arrests = PlayerInfo[targetid][pArrested];
new drugs = PlayerInfo[targetid][pDrugs];
new mats = PlayerInfo[targetid][pMats];
// new boxdrugs = PlayerInfo[targetid][pBoxDrugs];
// new boxmats = PlayerInfo[targetid][pBoxMats];
// new wanted = WantedLevel[targetid];
// new adminlevel = PlayerInfo[targetid][pAdmin];
new level = PlayerInfo[targetid][pLevel];
new exp = PlayerInfo[targetid][pExp];
new kills = PlayerInfo[targetid][pKills];
new pnumber = PlayerInfo[targetid][pPnumber];
new account = PlayerInfo[targetid][pAccount];
new nxtlevel = PlayerInfo[targetid][pLevel]+1;
new expamount = nxtlevel*levelexp;
new costlevel = nxtlevel*levelcost;//10k for testing purposes
// new housekey = PlayerInfo[targetid][pPhousekey];
// new bizkey = PlayerInfo[targetid][pPbiskey];
// new intir = PlayerInfo[targetid][pInt];
// new local = PlayerInfo[targetid][pLocal];
new Float:shealth = PlayerInfo[targetid][pSHealth];
new Float:health;
new name[MAX_PLAYER_NAME];
GetPlayerName(targetid, name, sizeof(name));
GetPlayerHealth(targetid,health);
new Float:px,Float:py,Float:pz;
new Float:plHealth, Float:plArmour;
GetPlayerPos(targetid, px, py, pz);
new plIP[20];
GetPlayerHealth(targetid,plHealth);
GetPlayerArmour(targetid,plArmour);
GetPlayerIp(playerid,plIP,sizeof(plIP));
new string1[200],string2[200],string3[200],string4[200],string5[200],string6[200],string7[200],string8[200],string9[200],string10[200],string11[200],string12[200],string13[200],string15[200],string18[200],string19[200],string20[200],string21[200],string22[200],string23[200],string24[200],string25[200],string26[200],rest[1500];
format(string1, sizeof string1, "{00E500}======[Stats von %s]======{FFFFFF}", name);
format(string2, sizeof string2, "{FF0000}------------[Allgemeines]------------{FFFFFF}");
format(string3, sizeof string3, " Level\t\t\t\t[%d]", level);
format(string4, sizeof string4, " PayDay\t\t\t\t[in %d Minuten]", 45-PlayerInfo[targetid][pPlayMinutes]);
format(string5, sizeof string5, " Telefonnummer\t\t\t\t[%d]", pnumber);
format(string6, sizeof string6, " Verheiratet mit\t\t\t\t[%s]", married);
format(string7, sizeof string7, " Spawnenergie\t\t\t\t[%.1f]", shealth+50.0);
format(string8, sizeof string8, " Geschlecht\t\t\t\t[%s]", atext);
format(string9, sizeof string9, " Herkunft\t\t\t\t[%s]", otext);
format(string10, sizeof string10, " Alter\t\t\t\t[%d]", age);
format(string11, sizeof string11, " Job\t\t\t\t[%s]\n", jtext);
format(string12, sizeof string12, "{FF0000}------------[Fraktion/Gang]------------{FFFFFF}");
format(string13, sizeof string13, " Team\t\t\t\t[%s]", ttext);
format(string15, sizeof string15, " Rang\t\t\t\t[%s]", rtext);
format(string18, sizeof string18, "{FF0000}------------[Besitz]------------{FFFFFF}");
format(string19, sizeof string19, " Premium Rang\t\t\t\t[%s]", drank);
format(string20, sizeof string20, " Morde & Tode\t\t\t\t[%d / %d]", kills,deaths);
format(string21, sizeof string21, " Bargeld\t\t\t\t[%d]", cash);
format(string22, sizeof string22, " Bankkonto\t\t\t\t[%d]", account);
format(string23, sizeof string23, " Materialien/Drogen\t\t\t\t[%d / %d]", mats, drugs);
format(string24, sizeof string24, " Verwarnungen\t\t\t\t[%d]", PlayerInfo[targetid][pWarns]);
format(string25, sizeof string25, " Respektpunkte\t\t\t\t[%d / %d]", exp, expamount);
format(string26, sizeof string26, " Lv. Up kosten\t\t\t\t[%d $]", costlevel);
//format(string27, sizeof string27, " Lotto Nummer [%d]",lotto);
format(rest, sizeof rest, "%s\n\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s", string1,string2,string3,string4,string5,string6,string7,string8,string9,string10,string11,string12,string13,string15,string18,string19,string20,string21,string22,string23,string24,string25,string26);
ShowPlayerDialog(playerid,30,DIALOG_STYLE_MSGBOX,"Statstik",rest,"Ok","");
}
return 1;
}
Function OnPlayerDeath(playerid, killerid, reason)
else if(IsACop(playerid))
{
if(IsPlayerConnected(killerid))
{
PlayerInfo[playerid][pKills]++;
if(IsACop(playerid))//hier muss Killerid hin
{
PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
GivePlayerMoney(killerid, -suecost);
GivePlayerMoney(playerid, suecost+100);
}
else if(IsANichtCop(killerid))
{
WantedPoints[killerid] += 7;
if(reason != 49)
{
CopMord[playerid] = 1;
SetPlayerCriminal(killerid,225,"Polizei Mord");
}
else if (reason == 49)
{
CopMord[playerid] = 1;
SetPlayerCriminal(killerid,225,"Fahrerflucht");
}
}
}
}
else if(IsANichtCop(killerid))
{
if(IsPlayerConnected(playerid))
{
PlayerInfo[playerid][pKills]++;
WantedPoints[killerid] += 5;
if(reason != 49)
{
CopMord[playerid] = 0;
SetPlayerCriminal(killerid,225,"Zivilisten Mord");
}
else if (reason == 49)
{
CopMord[playerid] = 0;
SetPlayerCriminal(killerid,225,"Fahrerflucht");
}
}
}
}
Hey,
Ich möchte das wenn ein Spieler einen Polizisten tötet 7WTDs und bei einem Zivilisten/Gang ler 5WTDs
Das habe ich so
Function OnPlayerDeath(playerid, killerid, reason)
else if(IsACop(playerid))
{
if(IsPlayerConnected(killerid))
{
PlayerInfo[playerid][pKills]++;
if(IsACop(playerid))//Polizist Tötet Polizist
{
PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
GivePlayerMoney(killerid, -suecost);
GivePlayerMoney(playerid, suecost+100);
}
else if(IsANichtCop(killerid))
{
WantedPoints[killerid] += 7;
if(reason != 49)
{
CopMord[playerid] = 1;
SetPlayerCriminal(killerid,225,"Polizei Mord");
}
else if (reason == 49)
{
CopMord[playerid] = 1;
SetPlayerCriminal(killerid,225,"Fahrerflucht");
}
}
}
}
else if(IsANichtCop(killerid))
{
if(IsPlayerConnected(playerid))
{
PlayerInfo[playerid][pKills]++;
WantedPoints[killerid] += 5;
if(reason != 49)
{
CopMord[playerid] = 0;
SetPlayerCriminal(killerid,225,"Zivilisten Mord");
}
else if (reason == 49)
{
CopMord[playerid] = 0;
SetPlayerCriminal(killerid,225,"Fahrerflucht");
}
}
}
}
Function SetPlayerCriminal(playerid,declare,reason[])
{
if(IsPlayerConnected(playerid))
{
PlayerInfo[playerid][pCrimes] += 1;
new turned[MAX_PLAYER_NAME];
new turner[MAX_PLAYER_NAME];
new turnmes[128];
new wantedmes[128];
new wlevel;
strmid(PlayerCrime[playerid][pAccusedof], reason, 0, strlen(reason), 255);
GetPlayerName(playerid, turned, sizeof(turned));
if (declare == 255)
{
format(turner, sizeof(turner), "Unbekannt");
strmid(PlayerCrime[playerid][pVictim], turner, 0, strlen(turner), 255);
}
else
{
if(IsPlayerConnected(declare))
{
GetPlayerName(declare, turner, sizeof(turner));
strmid(PlayerCrime[playerid][pVictim], turner, 0, strlen(turner), 255);
strmid(PlayerCrime[declare][pBplayer], turned, 0, strlen(turned), 255);
strmid(PlayerCrime[declare][pAccusing], reason, 0, strlen(reason), 255);
}
}
if(CopMord[playerid] == 1)
{
CopMord[playerid] = 0;
WantedLevel[playerid]+=7;
}
else
{
CopMord[playerid] = 0;
WantedLevel[playerid]+=5;
}
wlevel = WantedLevel[playerid];
format(turnmes, sizeof(turnmes), "Du hast ein Verbrechen begangen ( %s ). Zeuge: %s.",reason,turner);
SendClientMessage(playerid, COLOR_LIGHTRED, turnmes);
format(wantedmes, sizeof(wantedmes), "Momentanes Wantedlevel: %d", wlevel);
SendClientMessage(playerid, COLOR_YELLOW, wantedmes);
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(IsACop(i))
{
format(cbjstore, sizeof(turnmes), "HQ: Alle Einheiten: Zeuge: %s",turner);
SendClientMessage(i, TEAM_BLUE_COLOR, cbjstore);
format(cbjstore, sizeof(turnmes), "HQ: Verbrechen: %s, Gesuchter: %s",reason,turned);
SendClientMessage(i, TEAM_BLUE_COLOR, cbjstore);
}
}
}
}
}
Danke im Vorraus
Function Bann(string[])
{
new entry[256];
format(entry, sizeof(entry), "%s\n",string);
new File:hFile;
hFile = fopen("/Logs/Bann.log", io_append);
fwrite(hFile, entry);
fclose(hFile);
}
in deinem Befehl einfach
Bann(string);
format(string,sizeof(string),"%s hat %S gebannt");
Hallo,
Ich bearbeite ein GF Script
Und da ist der Befehl /FKasse drin und wenn ich mir den anschaue
Verstehe ich nicht wie es auf die Fraktions ID kommt die der Leader hat
new FraktionsKasse[24];
// >>>>>>>>>>>>>>>>> Fraktionskassen-System <<<<<<<<<<<<<<<<<
if(strcmp(cmd,"/fkasse",true) == 0)
{
new fraktion = 0;
if(PlayerInfo[playerid][pMember] > 0) fraktion = PlayerInfo[playerid][pMember] - 1; //Warum hier minus 1??
if(PlayerInfo[playerid][pLeader] > 0) fraktion = PlayerInfo[playerid][pLeader] - 1;
if(fraktion >= 0)
{
tmp = strtok(cmdtext,idx);
if(!strlen(tmp))
{
SendClientMessage(playerid,COLOR_GRAD5," /fkasse [einzahlen/auszahlen] [Betrag]");
format(string,sizeof(string)," Derzeit sind $%d in der Fraktionskasse!",FraktionsKasse[fraktion]);
SendClientMessage(playerid,COLOR_GRAD5,string);
return 1;
}
if(strcmp(tmp,"einzahlen",true) == 0)
{
tmp = strtok(cmdtext,idx);
if(!strlen(tmp))
{
SendClientMessage(playerid,COLOR_GRAD5," /fkasse einzahlen [Betrag]");
format(string,sizeof(string)," Derzeit sind $%d in der Fraktionskasse!",FraktionsKasse[fraktion]);
SendClientMessage(playerid,COLOR_GRAD5,string);
return 1;
}
new amount = strval(tmp);
if(amount < 0 || amount > 1000000) return SendClientMessage(playerid,COLOR_WHITE," Bitte nur Summen in Höhe von 1 bis 1 Million Dollar!");
if(GetPlayerMoney(playerid) < amount) return SendClientMessage(playerid,COLOR_WHITE," Du hast nicht soviel Geld um es einzuzahlen!");
FraktionsKasse[fraktion] += amount;
GivePlayerMoney(playerid,-amount);
format(string,sizeof(string)," Du hast $%d in die Fraktionskasse eingezahlt! Total: $%d",amount,FraktionsKasse[fraktion]);
SendClientMessage(playerid,COLOR_WHITE,string);
format(string,sizeof(string)," %s hat $%d in die Fraktionskasse eingezahlt! Total: $%d",sendername,amount,FraktionsKasse[fraktion]);
SendLeaderMSG(fraktion+1,COLOR_LIGHTBLUE,string);
SaveFraktionsKassen();
}
else if(strcmp(tmp,"auszahlen",true) == 0)
{
tmp = strtok(cmdtext,idx);
if(!strlen(tmp))
{
SendClientMessage(playerid,COLOR_GRAD5," /fkasse auszahlen [Betrag]");
format(string,sizeof(string)," Derzeit sind $%d in der Fraktionskasse!",FraktionsKasse[fraktion]);
SendClientMessage(playerid,COLOR_GRAD5,string);
return 1;
}
new amount = strval(tmp);
if(PlayerInfo[playerid][pLeader] == 0) return SendClientMessage(playerid,COLOR_WHITE," Nur Leader dürfen Geld aus der Fraktionskasse nehmen!");
if(amount < 0 || amount > 1000000) return SendClientMessage(playerid,COLOR_WHITE," Bitte nur Summen in Höhe von 1 bis 1 Million Dollar!");
if((FraktionsKasse[fraktion] - amount) < 0) return SendClientMessage(playerid,COLOR_WHITE," Du kannst keine Schulden machen!");
FraktionsKasse[fraktion] -= amount;
GivePlayerMoney(playerid,amount);
format(string,sizeof(string)," Du hast $%d aus der Fraktionskasse genommen! Total: $%d",amount,FraktionsKasse[fraktion]);
SendClientMessage(playerid,COLOR_WHITE,string);
format(string,sizeof(string)," %s hat $%d aus der Fraktionskasse genommen! Total: $%d",sendername,amount,FraktionsKasse[fraktion]);
SendLeaderMSG(fraktion+1,COLOR_LIGHTBLUE,string);
SaveFraktionsKassen();
}
else
{
SendClientMessage(playerid,COLOR_GRAD5," /fkasse [einzahlen/auszahlen] [Betrag]");
format(string,sizeof(string)," Derzeit sind $%d in der Fraktionskasse!",FraktionsKasse[fraktion]);
SendClientMessage(playerid,COLOR_GRAD5,string);
}
}
else SendClientMessage(playerid,COLOR_WHITE," Du bist in gar keiner Fraktion!");
return 1;
}
Danke wenn ihr mir das erklären könnt
mfg
Function Stats(playerid,targetid)
{
if(IsPlayerConnected(targetid))
{
new cash = GetPlayerMoney(targetid);
new atext[20];
if(PlayerInfo[targetid][pSex] == 1) { atext = "Männlich"; }
else if(PlayerInfo[targetid][pSex] == 2) { atext = "Weiblich"; }
new otext[20];
if(PlayerInfo[targetid][pOrigin] == 1) { otext = "Deutschland"; }
else if(PlayerInfo[targetid][pOrigin] == 2) { otext = "Osterreich"; }
else if(PlayerInfo[targetid][pOrigin] == 3) { otext = "Schweiz"; }
else if(PlayerInfo[targetid][pOrigin] == 4) { otext = "Türkei"; }
new ttext[20];
new dtext[20];
if(STDPlayer[targetid] == 1) { dtext = "Chlamydia"; }
else if(STDPlayer[targetid] == 2) { dtext = "Gonorrhea"; }
else if(STDPlayer[targetid] == 3) { dtext = "Syphilis"; }
else { dtext = "Keine"; }
new ftext[124];
if(PlayerInfo[targetid][pMember] == 0 || PlayerInfo[targetid][pLeader] == 0)//Zivilist
{
ttext = "Zivilist";
}
else if(PlayerInfo[targetid][pMember] == 1 || PlayerInfo[targetid][pLeader] == 1)//PD Ranks
{
ttext = "SFPD";
}
else if(PlayerInfo[targetid][pMember] == 2 || PlayerInfo[targetid][pLeader] == 2)//FBI Ranks
{
ttext = "FBI";
}
else if(PlayerInfo[targetid][pMember] == 3 || PlayerInfo[targetid][pLeader] == 3)//ARMY
{
ttext = "ARMY";
}
else if(PlayerInfo[targetid][pMember] == 7 || PlayerInfo[targetid][pLeader] == 7)
{
ttext = "Regierung";
}
else if(PlayerInfo[targetid][pMember] == 8 || PlayerInfo[targetid][pLeader] == 8)//Hitman Ranks
{
ttext = "Hitman";
}
else if(PlayerInfo[targetid][pMember] == 9 || PlayerInfo[targetid][pLeader] == 9)//NR Ranks
{
ttext = "San news";
}
else if(PlayerInfo[targetid][pMember] == 10 || PlayerInfo[targetid][pLeader] == 10)//Taxi Company Ranks
{
ttext = "Taxi";
}
else if(IsAnInstructor(targetid))//Driving/Flying School Ranks
{
ttext = "Fahrschule";
}
else if(PlayerInfo[targetid][pMember] == 13 || PlayerInfo[targetid][pLeader] == 13)//GS
{
ttext = "Grove Street";
}
else if(PlayerInfo[targetid][pMember] == 14 || PlayerInfo[targetid][pLeader] == 14)//ballas
{
ttext = "Ballas";
}
else if(PlayerInfo[targetid][pMember] == 15 || PlayerInfo[targetid][pLeader] == 15)//hells
{
ttext = "Hells Angels";
}
else if(PlayerInfo[targetid][pMember] == 17 || PlayerInfo[targetid][pLeader] == 17)//LA
{
ttext = "la Aztecas";
}
else if(PlayerInfo[targetid][pMember] == 20 || PlayerInfo[targetid][pLeader] == 20)//Terror
{
ttext = "Terror";
}
else if(PlayerInfo[targetid][pMember] == 21 || PlayerInfo[targetid][pLeader] == 21)//wheelman
{
ttext = "Wheelman";
}
else if(PlayerInfo[targetid][pMember] == 22 || PlayerInfo[targetid][pLeader] == 22)//SWAT
{
ttext = "SWAT";
}
new f2text[20];
new rtext[64];
if(PlayerInfo[targetid][pMember] == 0 || PlayerInfo[targetid][pLeader] == 0)//Zivilist
{
if(PlayerInfo[targetid][pRank] == 0) { rtext = "Zivilist"; }
}
else if(PlayerInfo[targetid][pMember] == 1 || PlayerInfo[targetid][pLeader] == 1)//PD Ranks
{
if(PlayerInfo[targetid][pRank] == 12) { rtext = "Leitender Polizeidirektor"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "Polizeidirektor"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "Polizeioberrat"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Polizeirat"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Erster Polizeihauptkommissar"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Polizeihauptkommissar"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Polizeioberkommissar"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Polizeikommissar"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Polizeihauptmeister"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Polizeiobermeister"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Polizeimeister"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Polizeimeisteranwärter"; }
}
else if(PlayerInfo[targetid][pMember] == 2 || PlayerInfo[targetid][pLeader] == 2)//FBI Ranks
{
if(PlayerInfo[targetid][pRank] == 10) { rtext = "Director"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Deputy Director"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Assistent Director"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Special Agent in Charge"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Assistent Special Agent in Charge"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Supervisory Special Agent"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Special Agent"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "New Agent"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Azubi"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Praktikant"; }
}
else if(PlayerInfo[targetid][pMember] == 3 || PlayerInfo[targetid][pLeader] == 3)//ARMY
{
if(PlayerInfo[targetid][pRank] == 13) { rtext = "General"; }
else if(PlayerInfo[targetid][pRank] == 12) { rtext = "General Major"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "Oberst"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "Major"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Oberleutnant"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Leutnant"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Oberstabsfeldwebel"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Feldwebel"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Oberoffizier"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Stabsunteroffizier"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Unteroffizier"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Obergefreiter"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Gefreiter"; }
}
else if(PlayerInfo[targetid][pMember] == 7 || PlayerInfo[targetid][pLeader] == 7)
{
if(PlayerInfo[targetid][pRank] == 12) { rtext = "Bundespräsident"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "Bundeskanzler"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "Staatsminister"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "Finanz-Minister"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "Steuer-Minister"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "Minister"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Geheimdienst-Leiter "; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Geheimdienst"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Geheimdienst-Azubi"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Personenschutz-Leiter"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Personenschutz"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Personenschutz-Azubi"; }
}
else if(PlayerInfo[targetid][pMember] == 8 || PlayerInfo[targetid][pLeader] == 8)//Hitman Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Neuling"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Killer"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Profi Killer"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Schütze"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Vice Director"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director"; }
}
else if(PlayerInfo[targetid][pMember] == 9 || PlayerInfo[targetid][pLeader] == 9)//NR Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Intern"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Lokaler Reporter"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Lokaler Bearbeiter"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Netzwerk Manager"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Netzwerk Bearbeiter"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Netzwerk Hersteller"; }
else { rtext = "Intern"; }
}
else if(PlayerInfo[targetid][pMember] == 10 || PlayerInfo[targetid][pLeader] == 10)//Taxi Company Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Taxi Fahrer Azubi"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Taxi Neuling"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Taxi Fahrer"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Zuteiler"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Schichtzuteiler"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Taxi Firmen Besitzer"; }
else { rtext = "Trainee"; }
}
else if(IsAnInstructor(targetid))//Driving/Flying School Ranks
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Praktikant"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Azubi"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Fahrlehrer"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Manager"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co Boss"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
}
else if(PlayerInfo[targetid][pMember] == 13 || PlayerInfo[targetid][pLeader] == 13)//GS
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co-Boss"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Gangster"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Homie"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Bro"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Sidekick"; }
}
else if(PlayerInfo[targetid][pMember] == 14 || PlayerInfo[targetid][pLeader] == 14)//ballas
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co-Boss"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Gangster"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Homie"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Bro"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Sidekick"; }
}
else if(PlayerInfo[targetid][pMember] == 15 || PlayerInfo[targetid][pLeader] == 15)//hells
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Anführer"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Stell. Anführer"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Gruftie"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Rüpel"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Rowdy"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Grossfahrer"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Rollerfahrer"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Fahrradfahrer"; }
}
else if(PlayerInfo[targetid][pMember] == 17 || PlayerInfo[targetid][pLeader] == 17)//LA
{
if(PlayerInfo[playerid][pRank] == 6) { rtext = "President"; }
else if(PlayerInfo[playerid][pRank] == 5) { rtext = "Co-President"; }
else if(PlayerInfo[playerid][pRank] == 4) { rtext = "Bandito"; }
else if(PlayerInfo[playerid][pRank] == 3) { rtext = "Cazador"; }
else if(PlayerInfo[playerid][pRank] == 2) { rtext = "Compadre"; }
else if(PlayerInfo[playerid][pRank] == 1) { rtext = "Amigo"; }
}
else if(PlayerInfo[targetid][pMember] == 20 || PlayerInfo[targetid][pLeader] == 20)//Terror
{
if(PlayerInfo[targetid][pRank] == 6) { rtext = "Boss"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co-Boss"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Terrorist"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Attentäter"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Auszubildender Attentäter"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "Terrorzwerg"; }
}
else if(PlayerInfo[targetid][pMember] == 21 || PlayerInfo[targetid][pLeader] == 21)//wheelman
{
if(PlayerInfo[targetid][pRank] == 1) { rtext = "Anfänger"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Söldner"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Special Söldner"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Ausbilder"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Co Direktor"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Direktor"; }
}
else if(PlayerInfo[targetid][pMember] == 22 || PlayerInfo[targetid][pLeader] == 22)//SWAT
{
if(PlayerInfo[targetid][pRank] == 12) { rtext = "SWAT-General"; }
else if(PlayerInfo[targetid][pRank] == 11) { rtext = "SWAT-Major-General"; }
else if(PlayerInfo[targetid][pRank] == 10) { rtext = "SWAT-Major"; }
else if(PlayerInfo[targetid][pRank] == 9) { rtext = "SWAT-Lieutenant"; }
else if(PlayerInfo[targetid][pRank] == 8) { rtext = "SWAT-Sergeant"; }
else if(PlayerInfo[targetid][pRank] == 7) { rtext = "SWAT-Investigator"; }
else if(PlayerInfo[targetid][pRank] == 6) { rtext = "SWAT-Inspector"; }
else if(PlayerInfo[targetid][pRank] == 5) { rtext = "SWAT-Detective"; }
else if(PlayerInfo[targetid][pRank] == 4) { rtext = "SWAT-Corporal"; }
else if(PlayerInfo[targetid][pRank] == 3) { rtext = "SWAT-Officer"; }
else if(PlayerInfo[targetid][pRank] == 2) { rtext = "SWAT-Trooper"; }
else if(PlayerInfo[targetid][pRank] == 1) { rtext = "SWAT-Greenhorn"; }
}
new jtext[20];
if(PlayerInfo[targetid][pJob] == 0) { jtext = "Keinen"; }
else if(PlayerInfo[targetid][pJob] == 1) { jtext = "Detektiv"; }
else if(PlayerInfo[targetid][pJob] == 2) { jtext = "Anwalt"; }
else if(PlayerInfo[targetid][pJob] == 3) { jtext = "Hure"; }
else if(PlayerInfo[targetid][pJob] == 4) { jtext = "Drogendealer"; }
else if(PlayerInfo[targetid][pJob] == 5) { jtext = "Autodieb"; }
else if(PlayerInfo[targetid][pJob] == 6) { jtext = "Farmer"; }
else if(PlayerInfo[targetid][pJob] == 7) { jtext = "Mechaniker"; }
else if(PlayerInfo[targetid][pJob] == 8) { jtext = "Bodyguard"; }
else if(PlayerInfo[targetid][pJob] == 9) { jtext = "Waffendealer"; }
else if(PlayerInfo[targetid][pJob] == 10) { jtext = "Autohändler"; }
else if(PlayerInfo[targetid][pJob] == 12) { jtext = "Boxer"; }
else if(PlayerInfo[targetid][pJob] == 14) { jtext = "Busfahrer"; }
else if(PlayerInfo[targetid][pJob] == 15) { jtext = "Zeitungsjunge"; }
else if(PlayerInfo[targetid][pJob] == 16) { jtext = "Pilot"; }
else if(PlayerInfo[targetid][pJob] == 17) { jtext = "Müllmann"; }
else if(PlayerInfo[targetid][pJob] == 20) { jtext = "Hartz IV"; }
else if(PlayerInfo[targetid][pJob] == 21) { jtext = "Taschendieb"; }
else { jtext = "Keinen Job"; }
new drank[20];
if(PlayerInfo[targetid][pDonateRank] == 0) { drank = "Keinen"; }
else if(PlayerInfo[targetid][pDonateRank] == 1) { drank = "Donator"; }
else if(PlayerInfo[targetid][pDonateRank] == 2) { drank = "Premium User"; }
else if(PlayerInfo[targetid][pDonateRank] == 3) { drank = "EhrenMember"; }
else if(PlayerInfo[targetid][pDonateRank] == 4) { drank = "EliteMember"; }
else { drank = "Keinen"; }
new married[20];
strmid(married, PlayerInfo[targetid][pMarriedTo], 0, strlen(PlayerInfo[targetid][pMarriedTo]), 255);
new age = PlayerInfo[targetid][pAge];
// new ptime = PlayerInfo[targetid][pConnectTime];
// new lotto = PlayerInfo[targetid][pLottoNr];
new deaths = PlayerInfo[targetid][pDeaths];
// new fishes = PlayerInfo[targetid][pFishes];
// new bigfish = PlayerInfo[targetid][pBiggestFish];
// new crimes = PlayerInfo[targetid][pCrimes];
// new arrests = PlayerInfo[targetid][pArrested];
new drugs = PlayerInfo[targetid][pDrugs];
new mats = PlayerInfo[targetid][pMats];
// new boxdrugs = PlayerInfo[targetid][pBoxDrugs];
// new boxmats = PlayerInfo[targetid][pBoxMats];
// new wanted = WantedLevel[targetid];
// new adminlevel = PlayerInfo[targetid][pAdmin];
new level = PlayerInfo[targetid][pLevel];
new exp = PlayerInfo[targetid][pExp];
new kills = PlayerInfo[targetid][pKills];
new pnumber = PlayerInfo[targetid][pPnumber];
new account = PlayerInfo[targetid][pAccount];
new nxtlevel = PlayerInfo[targetid][pLevel]+1;
new expamount = nxtlevel*levelexp;
new costlevel = nxtlevel*levelcost;//10k for testing purposes
new Float:shealth = PlayerInfo[targetid][pSHealth];
new Float:health;
new name[MAX_PLAYER_NAME];
GetPlayerName(targetid, name, sizeof(name));
GetPlayerHealth(targetid,health);
new Float:px,Float:py,Float:pz;
new Float:plHealth, Float:plArmour;
GetPlayerPos(targetid, px, py, pz);
new plIP[20];
GetPlayerHealth(targetid,plHealth);
GetPlayerArmour(targetid,plArmour);
GetPlayerIp(playerid,plIP,sizeof(plIP));
new string1[200],string2[200],string3[200],string4[200],string5[200],string6[200],string7[200],string8[200],string9[200],string10[200],string11[200],string12[200],string13[200],string14[200],string15[200],string16[200],string17[200],string18[200],string19[200],string20[200],string21[200],string22[200],string23[200],string24[200],string25[200],string26[200],rest[1500];
format(string1, sizeof string1, "{00E500}======[Stats von %s]======{FFFFFF}", name);
format(string2, sizeof string2, "{FF0000}------------[Allgemeines]------------{FFFFFF}");
format(string3, sizeof string3, " Level\t\t\t\t[%d]", level);
format(string4, sizeof string4, " PayDay\t\t\t\t[in %d Minuten]", 45-PlayerInfo[targetid][pPlayMinutes]);
format(string5, sizeof string5, " Telefonnummer\t\t\t[%d]", pnumber);
format(string6, sizeof string6, " Verheiratet mit\t\t\t[%s]", married);
format(string7, sizeof string7, " Spawnenergie\t\t\t[%.1f]", shealth+50.0);
format(string8, sizeof string8, " Geschlecht\t\t\t[%s]", atext);
format(string9, sizeof string9, " Herkunft\t\t\t[%s]", otext);
format(string10, sizeof string10, " Alter\t\t\t\t[%d]", age);
format(string11, sizeof string11, " Job\t\t\t\t[%s]\n", jtext);
format(string12, sizeof string12, "{FF0000}------------[Fraktion/Gang]------------{FFFFFF}");
format(string13, sizeof string13, " Team\t\t\t\t[%s]", ttext);
format(string14, sizeof string14, " Organisation\t\t\t[%s]", ftext);
format(string15, sizeof string15, " Rang\t\t\t\t[%s]", rtext);
format(string16, sizeof string16, " Familie\t\t\t\t[%s]", f2text);
format(string17, sizeof string17, " Zuschuss\t\t\t[%d$]",PlayerInfo[targetid][pGehalt]);
format(string18, sizeof string18, "{FF0000}------------[Besitz]------------{FFFFFF}");
format(string19, sizeof string19, " Premium Rang\t\t\t[%s]", drank);
format(string20, sizeof string20, " Morde & Tode\t\t\t[%d / %d]", kills,deaths);
format(string21, sizeof string21, " Bargeld\t\t\t[%d]", cash);
format(string22, sizeof string22, " Bankkonto\t\t\t[%d]", account);
format(string23, sizeof string23, " Materialien/Drogen\t\t[%d / %d]", mats, drugs);
format(string24, sizeof string24, " Verwarnungen\t\t\t[%d]", PlayerInfo[targetid][pWarns]);
format(string25, sizeof string25, " Respektpunkte\t\t\t[%d / %d]", exp, expamount);
format(string26, sizeof string26, " Lv. Up kosten\t\t\t[%d $]", costlevel);
format(rest, sizeof rest, "%s\n\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s", string1,string2,string3,string4,string5,string6,string7,string8,string9,string10,string11,string12,string13,string14,string15,string16,string17,string18,string19,string20,string21,string22,string23,string24,string25,string26);
ShowPlayerDialog(playerid,30,DIALOG_STYLE_MSGBOX,"Statstik",rest,"Ok","");
}
return 1;
}
Nur wenn man es ganz füllt
Hey,
Wenn ich /check mache kommt immer Unknown Command
Wie kann ich das beheben
if (strcmp(cmd, "/check", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD1, "Benutzung: /check [Spieler ID]");
return 1;
}
giveplayerid = ReturnUser(tmp);
if(IsPlayerConnected(giveplayerid))
{
if(giveplayerid != INVALID_PLAYER_ID)
{
Stats(playerid,giveplayerid);
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Der Spieler wurde nicht gefunden!");
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "Du bist nicht befugt!");
}
}
return 1;
}
Danke im Vorraus
Hey,
ich versuche grade den TodesPunk zu speichern
Nun ist bei OnPlayerLogin
Ein Problem und zwar bekomme ich
3Warnings
C:\Users\Nils\Desktop\lalalalal\gamemodes\DRP.pwn(21543) : warning 213: tag mismatch
C:\Users\Nils\Desktop\lalalalal\gamemodes\DRP.pwn(21544) : warning 213: tag mismatch
C:\Users\Nils\Desktop\lalalalal\gamemodes\DRP.pwn(21545) : warning 213: tag mismatch
Und das sind diese Zeilen
if( strcmp( key , "Tot_x" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[playerid][pTot_x] = floatstr( val ); }
if( strcmp( key , "Tot_y" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[playerid][pTot_y] = floatstr( val ); }
if( strcmp( key , "Tot_z" , true ) == 0 ) { val = ini_GetValue( Data ); PlayerInfo[playerid][pTot_z] = floatstr( val ); }
Wäre nett wenn ihr mir helfen könntet
Du gehst ins Script
Und suchst den autokauf Befehl
Strg + f
Und dann
Den befehl
MySQL_GatFloat
Da muss das hin
Halt mit xyz