Simple question -
Thedya - 26.01.2012
AddStaticVehicleEx(431,1792.1101,-1929.4487,13.5429,359.6343,1,1,1500)
at the and of the line '1500' is car's respawn time i think but i have a little question. 1500 = how much sec ? 1.5 min ? or..
and also 1 and 1 points r what?
thanks
Re: Simple question -
Tanush123 - 26.01.2012
1500 is 1.5 seconds so use
www.******.com to convert minutes to milliseconds.
Re: Simple question -
Gh05t_ - 26.01.2012
https://sampwiki.blast.hk/wiki/AddStaticVehicleEx
Quote:
Originally Posted by wiki
respawn_delay The delay until the car is respawned without a driver in minutes.
|
1 and 1 points are the id's primary and secondary colors.
Re: Simple question -
[ABK]Antonio - 26.01.2012
90 seconds is 1.5 minutes (1:30 (1 minute 30 seconds)) because there's 60 seconds in a minute and then we add the 30 to get half of a minute.
90,000 milliseconds is 1:30.
EDIT: woops, did my math wrong
Oh yeah, here's how you get milliseconds..You don't need a converter as it's basic math.
90*1000 = 90,000. So what's 1000? 1000 is 1 second is milliseconds. 90 is how much seconds we're trying to get, 1000 is 1 second in milliseconds.
How do we convert milliseconds to seconds? The answer is simple, 90000/1000 = 90 seconds
How we convert MINUTES to seconds is basically like this - take the minute, multiply it by 60. 15 minutes = 15*60=900.
Re: Simple question -
Thedya - 26.01.2012
Ah thanks for all of you.
Re: Simple question -
Thedya - 26.01.2012
I want to ask a new question on here, i didnt want to open a topic for this.
I wanna make /adminrespawncop command.
my cop cars are on forward ''IsACopCar(carid);''
When i use command, just 'IsACopCar's will respawn.. can you help me about it ?
Код:
if(strcmp(cmd, "/respawnallcar", true) == 0 || strcmp(cmd, "/ares", true) == 0) //
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] < 3)
{
SendClientMessage(playerid, COLOR_RED, "You r not admin.");
return 1;
}
new bool:unwanted[CAR_AMOUNT];
for(new player=0; player<MAX_PLAYERS; player++)
{
if(IsPlayerInAnyVehicle(player)) { unwanted[GetPlayerVehicleID(player)]=true; }
}
for(new car = 1; car <= 344; car++)
{
if(!unwanted[car]) SetVehicleToRespawn(car);
}
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "Server: %s bla bla.", sendername);
BroadCast(COLOR_YELLOW,string);
}
return 1;
}
For example command from my server. Bu its respawn all cars.
Re: Simple question -
[ABK]Antonio - 26.01.2012
pawn Код:
if(strcmp(cmd, "/respawncopcars", true) == 0)
{
for(new i=0; i < MAX_VEHICLES; i++)
{
if(IsACopCar(i))
{
SetVehicleToRespawn(i)
}
}
return 1;
}
Something like that? Though I would have to see your IsACopCar if that isn't right