Simple error, but I cannot find a fix for it!
#1

Hello,

So today I decided to do Companies in my Trucking server which runs PPC_Trucking.

I did everything then compiled and I get these errors:
pawno\include\PPC_FileOperations.inc(190) : warning 215: expression has no effect
pawno\include\PPC_FileOperations.inc(190) : error 001: expected token: ";", but found "["
pawno\include\PPC_FileOperations.inc(190) : error 029: invalid expression, assumed zero
pawno\include\PPC_FileOperations.inc(190) : warning 215: expression has no effect
pawno\include\PPC_FileOperations.inc(190) : error 001: expected token: ";", but found "]"


All of these are in the saving system.
I have no idea what is the problem, here is the full function too:

if (strcmp(ParameterName, "Company", false) == 0) // If the parametername is correct ("Company")
{
if (strcmp(ACompanyData[strval(ParameterValue)][Owner], Name, false) == 0) // Check if the player is the true owner of the Company
{
APlayerData[playerid][Company][ComIndex] = strval(ParameterValue); // Store the CompanyID at the selected slot
ComIndex++; // Select the next Company-slot in case another Company-id is found
}
}

I hope someone can give me suggestions on how to fix these errors.

Thank You.
Reply
#2

I will appreciate it if someone gave me a suggestion on a solution
Reply
#3

Can you show which line is 190? And sorround it with [ pawn] and [ /pawn] tags (without spaces) please?
Reply
#4

if (strcmp(ParameterName, "Company", false) == 0) // If the parametername is correct ("Company")
{
if (strcmp(ACompanyData[strval(ParameterValue)][Owner], Name, false) == 0) // Check if the player is the true owner of the Company
{
pawn Код:
APlayerData[playerid][Company][ComIndex] = strval(ParameterValue); // Store the CompanyID at the selected slot
ComIndex++; // Select the next Company-slot in case another Company-id is found
}
}
Reply
#5

Wheres the enum or whatever stores APlayerData? Have you mistyped anything?
Reply
#6

Hello,

Here is the enum:
pawn Код:
enum TCompanyData
{
    PickupID, // Holds the pickup-id that is linked to this Company
    Text3D:DoorText, // Holds the reference to the 3DText above the Company's pickup
    MapIconID, // Holds the ID of the mapicon for the business

    CompanyName[100], // Holds the name of the business (this will be displayed above the pickup near the business when it's owned)
    Float:CompanyX, // Holds the X-coordinate of the pickup for the Business
    Float:CompanyY, // Holds the Y-coordinate of the pickup for the Business
    Float:CompanyZ, // Holds the Z-coordinate of the pickup for the Business
    CompanyType, // Holds the type of business (well stacked pizza, burger shot, ...), this defines which icon and interior to use
    CompanyLevel, // Holds the level of upgrades the business has
    LastTransaction, // Holds the amount of minutes when the last transaction took place (buying the business or retrieving the money by the owner)
    bool:Owned, // Holds true if the Company is owned by somebody
    Owner[24] // Holds the name of the owner of the Company
}
// Holds the data for all houses
new ACompanyData[MAX_COMPANY][TCompanyData];
// This variable holds the Company-time (this value is increased every hour and is used to calculate the amount of money a Company
// has generated after the last transaction of the Company)
new CompanyTransactionTime;
Reply
#7

Quote:
Originally Posted by kasper1996
Посмотреть сообщение
Hello,

Here is the enum:
pawn Код:
enum TCompanyData
{
    PickupID, // Holds the pickup-id that is linked to this Company
    Text3D:DoorText, // Holds the reference to the 3DText above the Company's pickup
    MapIconID, // Holds the ID of the mapicon for the business

    CompanyName[100], // Holds the name of the business (this will be displayed above the pickup near the business when it's owned)
    Float:CompanyX, // Holds the X-coordinate of the pickup for the Business
    Float:CompanyY, // Holds the Y-coordinate of the pickup for the Business
    Float:CompanyZ, // Holds the Z-coordinate of the pickup for the Business
    CompanyType, // Holds the type of business (well stacked pizza, burger shot, ...), this defines which icon and interior to use
    CompanyLevel, // Holds the level of upgrades the business has
    LastTransaction, // Holds the amount of minutes when the last transaction took place (buying the business or retrieving the money by the owner)
    bool:Owned, // Holds true if the Company is owned by somebody
    Owner[24] // Holds the name of the owner of the Company
}
// Holds the data for all houses
new ACompanyData[MAX_COMPANY][TCompanyData];
// This variable holds the Company-time (this value is increased every hour and is used to calculate the amount of money a Company
// has generated after the last transaction of the Company)
new CompanyTransactionTime;
PS: there is more enum for Company.
If they are needed to show you, just tell me
Reply
#8

Anyone?
Reply
#9

Please, I would like some support from anyone.
Reply
#10

help?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)