Command Problem need help :( - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Command Problem need help :( (
/showthread.php?tid=156963)
Command Problem need help :( -
wofka13 - 24.06.2010
(Sry for my bad English

)
I have a problem with my Command.
Two things do not run
one is a variable and the other is a strmid:
Код:
if(strcmp(cmd, "/kaufen", true ) == 0)
{
if(INI_Open("Haus.cfg"))
{
for(new h = 0; h < sizeof(HausInfo); h++)
{
if(IsPlayerInRangeOfPoint(playerid, 3.0, HausInfo[h][eX], HausInfo[h][eY], HausInfo[h][eZ]))
{
if(GetPlayerMoney(playerid) < HausInfo[h][Preis])return 1;
new Name[MAX_PLAYER_NAME];
GetPlayerName(playerid, Name, MAX_PLAYER_NAME);
GivePlayerMoney(playerid, - HausInfo[h][Preis]);
SendClientMessage(playerid,FARBE_WEIЯ,"gekauft xD");
HausInfo[h][Vergeben] = 1;
strmid(HausInfo[h][Besitzer], Name, 0, strlen(Name), 24);
INI_Save();
INI_Close();
return 1;
}
}
}
return 1;
}
This 2 lines do not works:
Код:
HausInfo[h][Vergeben] = 1;
strmid(HausInfo[h][Besitzer], Name, 0, strlen(Name), 24);
the variable and the strmid is not running and I know why you can not really help her?