18.01.2011, 01:29
OKay, I am just really stuck on this one...
I have been doing this tutorial, I've followed it step by step yet, I still get errors.
---------------------------------------------------------------------------
TUTORIAL:
https://sampforum.blast.hk/showthread.php?tid=174575
----------------------------------------------------------------------------
The only place I am getting errors, has to do with PInfo.
----------------------------------------------------------------------------
Here's the Code:
new PInfo[MAX_PLAYERS][gPInfo];
enum gPInfo
{
Logged,
Regged,
Level
};
----------------------------------------------------------------------------
More Code: (Here's where I get the errors)
public OnPlayerConnect(playerid)
{
PInfo[playerid][Logged] = 0;
PInfo[playerid][Regged] = 0;
PInfo[playerid][Level] = 0;
new n[MAX_PLAYER_NAME], file[256];
GetPlayerName(playerid,n,sizeof(n));
format(file,sizeof(file),"MyAdmin/Users/%s.txt",n);
if(dini_Exists(file))
{
----------------------------------------------------------------------------
Here's the Compiler Output:
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : error 017: undefined symbol "PInfo"
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : warning 215: expression has no effect
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : error 001: expected token: ";", but found "]"
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : error 029: invalid expression, assumed zero
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
4 Errors.
-----------------------------------------------------------------------------
PROBLEMS:
1. Even though I have PInfo listed as a symbol, the compiler still says "Undefined Symbol"
2. It Tells me I need ";" instead of "]" on line 141. but I really don't see where it fits...
--------------------------------
I'm new to scripting, If you can tell..
I have been doing this tutorial, I've followed it step by step yet, I still get errors.
---------------------------------------------------------------------------
TUTORIAL:
https://sampforum.blast.hk/showthread.php?tid=174575
----------------------------------------------------------------------------
The only place I am getting errors, has to do with PInfo.
----------------------------------------------------------------------------
Here's the Code:
new PInfo[MAX_PLAYERS][gPInfo];
enum gPInfo
{
Logged,
Regged,
Level
};
----------------------------------------------------------------------------
More Code: (Here's where I get the errors)
public OnPlayerConnect(playerid)
{
PInfo[playerid][Logged] = 0;
PInfo[playerid][Regged] = 0;
PInfo[playerid][Level] = 0;
new n[MAX_PLAYER_NAME], file[256];
GetPlayerName(playerid,n,sizeof(n));
format(file,sizeof(file),"MyAdmin/Users/%s.txt",n);
if(dini_Exists(file))
{
----------------------------------------------------------------------------
Here's the Compiler Output:
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : error 017: undefined symbol "PInfo"
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : warning 215: expression has no effect
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : error 001: expected token: ";", but found "]"
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : error 029: invalid expression, assumed zero
C:\Users\SJC\Desktop\Mapping\GTARP\gamemodes\Admin Script.pwn(141) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
4 Errors.
-----------------------------------------------------------------------------
PROBLEMS:
1. Even though I have PInfo listed as a symbol, the compiler still says "Undefined Symbol"
2. It Tells me I need ";" instead of "]" on line 141. but I really don't see where it fits...
--------------------------------
I'm new to scripting, If you can tell..