Few Questions -
Alvin007 - 07.02.2015
Question I:
Код:
What's the Difference between a Pickup and a dynamic pickup.
Question II:
Using this loop, what would be the amount of the variable id? ( when the loop ends )
id = 5 or id = 10?
PHP код:
for(new id = 1; id < sizeof(BusinessInfo); id++)
//new BusinessInfo[5][2]
Question III:
Quote:
When a player spawns, the interior it is in is set to 0 by default?
|
Question IV:
Any small explanation about the variable idx please, i often see it as "playerid"
Quote:
forward loadbiz_data(idx, name[], value[]);
public loadbiz_data(idx, name[], value[])
|
Question V:
Cant make: BusinessInfo[id][bName]='None' ? Instead of
Quote:
format(string, sizeof(string), "None");
strmid(BusinessInfo[id][bName], string, 0, strlen(string), 255);
|
EDIT:
Question VI:
I can do such things?
PHP код:
enum pInfo
{
pBiz[5]
}
PlayerInfo[playerid][pBiz[0]]=1;
PlayerInfo[playerid][pBiz[1]]=1;
Or do i have to add
pBiz1
pBiz2
.
.
pBiz5
Question VII:
Quote:
How do i Disable the default stunt bonus?
|
And thanks.
AW: Few Questions -
Nero_3D - 07.02.2015
I: There is none, the dynamic pickup is the streamed version of the default, streamed = higher pickup limit, see
Limits (there could also be additional features in the streamer plugin if you need them)
II: id would be equal to sizeof(BusinessInfo) buf if 5 or 10 were higher or equal from the beginning id would be either 5 or 10
III: Yes
IV: Read the documentation of this function, "idx" is just a name (you could rename it to "foo" if you want)
V: Thats the limit of pawn, no way around it but you should use strcpy (based on strcat)
pawn Код:
#define strcpy(%0, strcat((%0[0] = EOS, %0),
// func
strcpy(BusinessInfo[id][bName], "None");
VI: Yes, it should look like PlayerInfo[playerid][pBiz][0] = 1, PlayerInfo[playerid][pBiz][1] = 1;
VII: I thought It is disabled by default but you can enable / disable it with
EnableStuntBonusForAll
Re : Few Questions -
Alvin007 - 07.02.2015
Thanks alot, you did not answer to the second question tho ..
I know that 'id' is going to get the sizeof(BusinessInfo) and stop there.
But is it equal to 5 or 10? ( for the example of the array: BusinessInfo[5][2] )
Re: Few Questions -
PowerPC603 - 07.02.2015
It would be 5, as the first size-indicator after the name of the array is set to 5.
"sizeof(BusinessInfo)" will return 5, but your loop won't reach 5 as the loop-condition says: "id < sizeof(BusinessInfo)".
Inside the loop, you'll get values for "id" from 1 to 4.
After the loop, your variable is gone as it's only created inside the loop ("new id = 1").
Re : Few Questions -
Alvin007 - 07.02.2015
Yeah thanks alot i got it, yeah it's < and not =< so it won't reach 5.
W/e i got what i was looking for.