Hallo Brotfischer,
Ich habe folgendes Problem beim Ausführen der SAMP Server Datei. Ich benutze Linux OpenSuse - AMD64
Wenn ich die samp03svr mit ./samp03svr Ausführen will bekomme ich folgenden Error:
Hallo Brotfischer,
Ich habe folgendes Problem beim Ausführen der SAMP Server Datei. Ich benutze Linux OpenSuse - AMD64
Wenn ich die samp03svr mit ./samp03svr Ausführen will bekomme ich folgenden Error:
public moneyabzug(playerid)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
new money = GetPlayerMoney(i);
if((money - PMoney[i]) < 0)
{
new MStringy[128];
valstr(MStringy,money - PMoney[i]);
if(strlen(MStringy)<=8)
{
new Stringy[128];
format(Stringy,sizeof(Stringy),"%08d",money - PMoney[i]);
TextDrawSetString(MoneyText[i],Stringy);
TextDrawShowForPlayer(i,MoneyText[i]);
KillTimer(MoneyHide[i]);
MoneyHide[playerid]=SetTimerEx("HideMoneyText",4000,0,"i",playerid);
}
}
}
PMoney[i] = money;
return 1;
So vll?
Hast du den an dem Autohaus etwas verändert?
Das hier ganz oben ins Script
new Text:Textdraw0;
new Text:Textdraw1;
new Text:Textdraw2;
new Text:Textdraw3;
new Text:Textdraw4;
new Text:Textdraw5;
new Text:Textdraw6;
new Text:Textdraw7;
new Text:Textdraw8;
Das unter OnGameModeInit
Textdraw0 = TextDrawCreate(41.000000,152.000000,"Zahltag");
Textdraw1 = TextDrawCreate(1.000000,153.000000,".");
Textdraw2 = TextDrawCreate(5.000000,166.000000," ");
Textdraw3 = TextDrawCreate(65.000000,166.000000," ");
Textdraw4 = TextDrawCreate(118.000000,166.000000," ");
Textdraw5 = TextDrawCreate(5.000000,180.000000," ");
Textdraw6 = TextDrawCreate(91.000000,180.000000," ");
Textdraw7 = TextDrawCreate(5.000000,194.000000," ");
Textdraw8 = TextDrawCreate(15.000000,219.000000," ");
TextDrawUseBox(Textdraw1,1);
TextDrawBoxColor(Textdraw1,0x0000ff66);
TextDrawTextSize(Textdraw1,175.000000,0.000000);
TextDrawAlignment(Textdraw0,0);
TextDrawAlignment(Textdraw1,0);
TextDrawAlignment(Textdraw2,0);
TextDrawAlignment(Textdraw3,0);
TextDrawAlignment(Textdraw4,0);
TextDrawAlignment(Textdraw5,0);
TextDrawAlignment(Textdraw6,0);
TextDrawAlignment(Textdraw7,0);
TextDrawAlignment(Textdraw8,0);
TextDrawBackgroundColor(Textdraw0,0x000000ff);
TextDrawBackgroundColor(Textdraw1,0x000000ff);
TextDrawBackgroundColor(Textdraw2,0x000000ff);
TextDrawBackgroundColor(Textdraw3,0x000000ff);
TextDrawBackgroundColor(Textdraw4,0x000000ff);
TextDrawBackgroundColor(Textdraw5,0x000000ff);
TextDrawBackgroundColor(Textdraw6,0x000000ff);
TextDrawBackgroundColor(Textdraw7,0x000000ff);
TextDrawBackgroundColor(Textdraw8,0x000000ff);
TextDrawFont(Textdraw0,0);
TextDrawLetterSize(Textdraw0,1.000000,1.000000);
TextDrawFont(Textdraw1,3);
TextDrawLetterSize(Textdraw1,1.000000,1.000000);
TextDrawFont(Textdraw2,1);
TextDrawLetterSize(Textdraw2,,1.000000,1.000000);
TextDrawFont(Textdraw3,1);
TextDrawLetterSize(Textdraw3,,1.000000,1.000000);
TextDrawFont(Textdraw4,1);
TextDrawLetterSize(Textdraw4,,1.000000,1.000000);
TextDrawFont(Textdraw5,1);
TextDrawLetterSize(Textdraw5,,1.000000,1.000000);
TextDrawFont(Textdraw6,1);
TextDrawLetterSize(Textdraw6,,1.000000,1.000000);
TextDrawFont(Textdraw7,1);
TextDrawLetterSize(Textdraw7,,1.000000,1.000000);
TextDrawFont(Textdraw8,1);
TextDrawLetterSize(Textdraw8,,1.000000,1.000000);
TextDrawColor(Textdraw0,0xffffffff);
TextDrawColor(Textdraw1,0xffffffff);
TextDrawColor(Textdraw2,0xffffffff);
TextDrawColor(Textdraw3,0xffffffff);
TextDrawColor(Textdraw4,0xffffffff);
TextDrawColor(Textdraw5,0xffffffff);
TextDrawColor(Textdraw6,0xffffffff);
TextDrawColor(Textdraw7,0xffffffff);
TextDrawColor(Textdraw8,0xffffffff);
TextDrawSetOutline(Textdraw0,1);
TextDrawSetOutline(Textdraw1,1);
TextDrawSetOutline(Textdraw2,1);
TextDrawSetOutline(Textdraw3,1);
TextDrawSetOutline(Textdraw4,1);
TextDrawSetOutline(Textdraw5,1);
TextDrawSetOutline(Textdraw6,1);
TextDrawSetOutline(Textdraw7,1);
TextDrawSetOutline(Textdraw8,1);
TextDrawSetProportional(Textdraw0,1);
TextDrawSetProportional(Textdraw1,1);
TextDrawSetProportional(Textdraw2,1);
TextDrawSetProportional(Textdraw3,1);
TextDrawSetProportional(Textdraw4,1);
TextDrawSetProportional(Textdraw5,1);
TextDrawSetProportional(Textdraw6,1);
TextDrawSetProportional(Textdraw7,1);
TextDrawSetProportional(Textdraw8,1);
TextDrawSetShadow(Textdraw1,1);
TextDrawSetShadow(Textdraw2,1);
TextDrawSetShadow(Textdraw3,1);
TextDrawSetShadow(Textdraw4,1);
TextDrawSetShadow(Textdraw5,1);
TextDrawSetShadow(Textdraw6,1);
TextDrawSetShadow(Textdraw7,1);
TextDrawSetShadow(Textdraw8,1);
Das durch deinen Payday ersetzen!
public PayDay()
{
new string[128];
new account,interest;
new rent = 0;
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(MoneyMessage[i]==1)
{
SendClientMessage(i, COLOR_LIGHTRED, "Du konntest deine Schulden nicht Bezahlen.");
GameTextForPlayer(i, "~r~Busted!", 2000, 1);
SetPlayerInterior(i, 6);
SetPlayerPos(i, 264.6288,77.5742,1001.0391);
PlayerInfo[i][pJailed] = 1;
ResetPlayerWeapons(i);
ResetPlayerMoney(i);
WantedPoints[i] = 0;
PlayerInfo[i][pJailTime] = 240;
format(string, sizeof(string), "Du bist eingesperrt für %d sekunden. Kaution: Keine", PlayerInfo[i][pJailTime]);
SendClientMessage(i, COLOR_LIGHTBLUE, string);
}
new playername2[MAX_PLAYER_NAME];
GetPlayerName(i, playername2, sizeof(playername2));
account = PlayerInfo[i][pAccount];
new key = PlayerInfo[i][pPhousekey];
if(key != 255)
{
rent = HouseInfo[key][hRent];
if(strcmp(playername2, HouseInfo[key][hOwner], true) == 0)
{
rent = 0;
}
else if(rent > GetPlayerMoney(i))
{
PlayerInfo[i][pPhousekey] = 255;
SendClientMessage(i, COLOR_WHITE, "You have been evicted.");
rent = 0;
}
HouseInfo[key][hTakings] = HouseInfo[key][hTakings]+rent;
}
new tmpintrate;
if (key != 255 && strcmp(playername2, HouseInfo[key][hOwner], true) == 0)
{
if(PlayerInfo[i][pDonateRank] > 0) { tmpintrate = intrate+4; }
else { tmpintrate = intrate+2; }//HouseInfo[key][hLevel]
}
else
{
if(PlayerInfo[i][pDonateRank] > 0) { tmpintrate = 3; }
else { tmpintrate = 1; }
}
if(PlayerInfo[i][pPayDay] >= 3)
{
Tax += TaxValue;//Should work for every player online
PlayerInfo[i][pAccount] -= TaxValue;
if(PlayerInfo[i][pDonateRank] > 0)
{
new bonus = PlayerInfo[i][pPayCheck] / 2;
PlayerInfo[i][pPayCheck] += bonus;
}
new checks = PlayerInfo[i][pPayCheck];
new ebill = (PlayerInfo[i][pAccount]/10000)*(PlayerInfo[i][pLevel]);
//new oil = (PlayerInfo[i][pPhousekey]*100);
ConsumingMoney[i] = 1;
GivePlayerMoney(i, checks);
if(PlayerInfo[i][pAccount] > 0)
{
PlayerInfo[i][pAccount] -= ebill;
SBizzInfo[4][sbTill] += ebill;
}
else
{
ebill = 0;
}
if(PlayerInfo[i][pPhousekey] != 255)
{
//PlayerInfo[i][pAccount] -= oil;
//SBizzInfo[3][sbTill] += oil;
}
else
{
//oil = 0;
}
if(PlayerInfo[i][pMember] == 0 && PlayerInfo[i][pLeader] == 0)
{
checks += 500;
}
interest = (PlayerInfo[i][pAccount]/10000)*(tmpintrate);
PlayerInfo[i][pExp]++;
PlayerPlayMusic(i);
PlayerInfo[i][pAccount] = account+interest;
format(string, sizeof(string),"Gehalt: $%d Miete: -$%d Steuern: -$%d", checks, rent, TaxValue);
TextDrawSetString(Textdraw2,string);
if(PlayerInfo[i][pPhousekey] != 255 || PlayerInfo[i][pPbiskey] != 255 && PlayerInfo[i][pHandyVer] == 1))
{
format(string, sizeof(string), " Strom Kosten: -$%d HandyVertrag: -$100", ebill);
TextDrawSetString(Textdraw3,string);
}
format(string, sizeof(string), " Zinsen: $%d [0.%d prozent]", interest,tmpintrate);
TextDrawSetString(Textdraw4,string);
format(string, sizeof(string), " Neuer Kontostand: $%d", PlayerInfo[i][pAccount]);
TextDrawSetString(Textdraw5,string);
TextDrawShowForPlayer(playerid,Text:Textdraw0);
TextDrawShowForPlayer(playerid,Text:Textdraw1);
TextDrawShowForPlayer(playerid,Text:Textdraw2);
TextDrawShowForPlayer(playerid,Text:Textdraw3);
TextDrawShowForPlayer(playerid,Text:Textdraw4);
TextDrawShowForPlayer(playerid,Text:Textdraw5);
TextDrawShowForPlayer(playerid,Text:Textdraw6);
TextDrawShowForPlayer(playerid,Text:Textdraw7);
TextDrawShowForPlayer(playerid,Text:Textdraw8);
format(string, sizeof(string), "~g~PayDay~y~!!!");
GameTextForPlayer(i, string, 5000, 1);
rent = 0;
PlayerInfo[i][pPayDay] = 0;
PlayerInfo[i][pPayCheck] = 0;
PlayerInfo[i][pConnectTime] += 1;
if(PlayerInfo[i][pDonateRank] > 0)
{
PlayerInfo[i][pPayDayHad] += 1;
if(PlayerInfo[i][pPayDayHad] >= 5)
{
PlayerInfo[i][pExp]++;
PlayerInfo[i][pPayDayHad] = 0;
}
}
}
else
{
SendClientMessage(i, COLOR_LIGHTRED, "* Du hast nicht lange Genug gespielt!");
}
}
else
{
SendClientMessage(i, COLOR_LIGHTRED, "* Du hast kannst keinen PayDay bekommen solange du AFK bist!");
}
}
Checkprop();
return 1;
}
Komplett Ungetestet!!!
Alles Löschen was mit "HouseCar" zu tun hat
public moneyabzug(playerid)
{
new money = GetPlayerMoney(playerid);
if((money - PMoney[playerid]) < 0)
{
new MStringy[128];
valstr(MStringy,money - PMoney[playerid]);
if(strlen(MStringy)<=8)
{
new Stringy[128];
format(Stringy,sizeof(Stringy),"%08d",money - PMoney[playerid]);
TextDrawSetString(MoneyText[playerid],Stringy);
for(new i = 0; i < MAX_PLAYERS; i++)
{
TextDrawShowForPlayer(i,MoneyText[playerid]);
}
KillTimer(MoneyHide[playerid]);
MoneyHide[playerid]=SetTimerEx("HideMoneyText",4000,0,"i",playerid);
}
}
PMoney[playerid] = money;
return 1;
Normalerweise so
-> Ungetestet
Cooles teil
//edit
du kannst es ja so machen das man in diesem Tool zwichen mehreren Sprachen Wählen kann