Reply to Re: scripting trouble, why always me
If you don't have an account, just leave the password field blank.
Ok. My DinkC Editor didn't find any errors, but it found some warnings. One of them is that &rock_placement wasn't declared in this script, so I assume that this is a global variable.
The second one, which is pretty serious, is that you should use "{" after an if statement.
From the DinkC Reference:
However, there is one critical error. This does not work for anything involving variables.
void talk(void)
{
int &temp = 0;
// This will not work!!
if (&life == &lifemax)
&temp = 1;
}
To properly assign variables in if statements, you must use the curly braces.
void talk(void)
{
int &temp = 0;
// This works fine.
if (&life == &lifemax)
{
&temp = 1;
}
}
I noticed that you used several times, expressions like this one:
if (&place >= 1000)
&place -= 1000;
The second one, which is pretty serious, is that you should use "{" after an if statement.
From the DinkC Reference:
However, there is one critical error. This does not work for anything involving variables.
void talk(void)
{
int &temp = 0;
// This will not work!!
if (&life == &lifemax)
&temp = 1;
}
To properly assign variables in if statements, you must use the curly braces.
void talk(void)
{
int &temp = 0;
// This works fine.
if (&life == &lifemax)
{
&temp = 1;
}
}
I noticed that you used several times, expressions like this one:
if (&place >= 1000)
&place -= 1000;






