Hi guys;
I´m reestructuring a large old project, and ran into a problem.
Two simple functions calls each other in separate scripts:
Function in script 1:
function player_mode(var* modeplayer)
{
if(modeplayer==1)
{
//initializes third camera mode
camera_mode=1;
CAMERASTART();
return;
}
if(modeplayer==2)
{
//initializes first person camera mode
camera_mode=2;
CAMERASTART();
return;
}
if (modeplayer>=3)
{
player_mode(1);
error("player mode not made yet!");
}
wait(1);
}
Functions in script 2:
//prototype
function player_mode(modeplayer);
function initial_event()
{
player_mode(1);
wait(1);
}
As the function calls for "player_mode", i get the following error:
Error in 'playermode.c' line 344:
Syntax error:Can´t convert P_GE:POINTER:LONG:LONG.
< if (modeplayer>=3)
>
I know i made a mistake, but where?
When i declared the prototype with the condidtions like "var* modeplayer" instead of simple "modeplayer", i was getting a syntax error.
Any help is appreciated, thanks in advance.