SA-MP Forums Archive
error 017: undefined symbol "Vehicle@YSII_Ag" - 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)
+--- Thread: error 017: undefined symbol "Vehicle@YSII_Ag" (/showthread.php?tid=657915)



error 017: undefined symbol "Vehicle@YSII_Ag" - OfekEfron - 17.08.2018

error 017: undefined symbol "Vehicle@YSII_Ag"
error 017: undefined symbol "Vehicle@YSII_Ag"

GetVehicleLinkedID(id)
{
foreach(new i: Vehicle)
{
if(VehicleInfo[i][vID] == id)
{
return i;
}
}

return INVALID_VEHICLE_ID;
}

what i need to do to fix it?


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - KinderClans - 17.08.2018

You need y_iterate/foreach include.


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - OfekEfron - 17.08.2018

Quote:
Originally Posted by KinderClans
Посмотреть сообщение
You need y_iterate/foreach include.
#include <foreach>
isnt good?


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - KinderClans - 17.08.2018

As i know, you need also y_iterate.


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - OfekEfron - 17.08.2018

Quote:
Originally Posted by KinderClans
Посмотреть сообщение
As i know, you need also y_iterate.
#include <y_iterate>
added this and its giving me the same error


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - KinderClans - 17.08.2018

#include <YSI\y_iterate>

Download whole YSI include pack and put this ^


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - GaMiX - 17.08.2018

you guys are very fast xd


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - OfekEfron - 17.08.2018

Quote:
Originally Posted by KinderClans
Посмотреть сообщение
#include <YSI\y_iterate>

Download whole YSI include pack and put this ^
still the same


Re: error 017: undefined symbol "Vehicle@YSII_Ag" - Unkovic - 17.08.2018

Quote:
Originally Posted by KinderClans
Посмотреть сообщение
#include <YSI\y_iterate>

Download whole YSI include pack and put this ^
First, Open the y_iterate and foreach and see difference xD

Also, I THINK that you cant foreach vehicles as players.
If you create ServerVehicles Iterators you can do that.