Moneybag location is not changing if not found
#2

Change this

PHP код:
forward MoneyBag();
public 
MoneyBag()
{
new 
string[175];
if(!
MoneyBagFound)
{
format(stringsizeof(string), "{FF9900}SERVER: The Money bag has not been found, it is still hidden in %s"MoneyBagLocation);
SendClientMessageToAll(-1string);
}
else if(
MoneyBagFound)
{
MoneyBagFound 0;
new 
randombag random(sizeof(MBSPAWN));
MoneyBagPos[0] = MBSPAWN[randombag][XPOS];
MoneyBagPos[1] = MBSPAWN[randombag][YPOS];
MoneyBagPos[2] = MBSPAWN[randombag][ZPOS];
format(MoneyBagLocationsizeof(MoneyBagLocation), "%s"MBSPAWN[randombag][Position]);
format(stringsizeof(string), "{FF9900}SERVER: The Money Bag has been hidden somewhere near/in %s!"MoneyBagLocation);
SendClientMessageToAll(-1string);
MoneyBagPickup CreatePickup(15502MoneyBagPos[0], MoneyBagPos[1], MoneyBagPos[2], -1);
}
return 
1;

To this

PHP код:
forward MoneyBag();
public 
MoneyBag()
{
    new 
string[175];
    new 
randombag random(sizeof(MBSPAWN));
    if(!
MoneyBagFound)
    {
        
SendClientMessageToAll(-1"{FF9900}SERVER: The Money bag has not been found, MoneyBag location changed.");
        
MoneyBagPos[0] = MBSPAWN[randombag][XPOS];
        
MoneyBagPos[1] = MBSPAWN[randombag][YPOS];
        
MoneyBagPos[2] = MBSPAWN[randombag][ZPOS];
        
format(MoneyBagLocationsizeof(MoneyBagLocation), "%s"MBSPAWN[randombag][Position]);
        
format(stringsizeof(string), "{FF9900}SERVER: MoneyBag has been placed elsewhere, probably at %s."MoneyBagLocation);
        
SendClientMessageToAll(-1string);
        
DestroyPickup(MoneyBagPickup);
        
MoneyBagPickup CreatePickup(15502MoneyBagPos[0], MoneyBagPos[1], MoneyBagPos[2], -1);
    }
    else if(
MoneyBagFound)
    {
        
MoneyBagFound 0;
        
MoneyBagPos[0] = MBSPAWN[randombag][XPOS];
        
MoneyBagPos[1] = MBSPAWN[randombag][YPOS];
        
MoneyBagPos[2] = MBSPAWN[randombag][ZPOS];
        
format(MoneyBagLocationsizeof(MoneyBagLocation), "%s"MBSPAWN[randombag][Position]);
        
format(stringsizeof(string), "{FF9900}SERVER: The Money Bag has been hidden somewhere near/in %s!"MoneyBagLocation);
        
SendClientMessageToAll(-1string);
        
MoneyBagPickup CreatePickup(15502MoneyBagPos[0], MoneyBagPos[1], MoneyBagPos[2], -1);
    }
    return 
1;

Reply


Messages In This Thread
Moneybag location is not changing if not found - by Rohit12 - 13.01.2018, 08:44
Re: Moneybag location is not changing if not found - by JaKe Elite - 13.01.2018, 08:53

Forum Jump:


Users browsing this thread: 1 Guest(s)