Reply to Re: Nuttree
If you don't have an account, just leave the password field blank.
Now I have the next problem.
================================
The nuttree
void main( void )
{
int &crap;
}
void talk( void )
{
say_stop("Hey, I found the Nuttree.", 1);
wait(250);
}
void hit( void )
{
&crap = scripts_used();
if (&crap > 170)
{
//don't make any more nuts, there are 165 already on the screen..)
return;
}
if(&boss == 1)
{
return
}
//lets make the nut fall down and give it a nut script
&crap = create_sprite( 158, 226, 0, 421, 23);
sp_speed(&crap, 1);
move_stop(&crap, 2, 226, 1)
sp_script(&crap, "s1-nut");
}
=======================================
s1-nut
void main( void )
{
int &boss;
sp_touch_damage(¤t_sprite, -1);
}
void touch( void )
{
int &junk = free_items();
if (&junk < 1)
{
say("I'm full! I can't pick up anything else.", 1);
return;
}
add_item("item-nut",438, 19);
if(&boss == 0)
{
external("s10-gobboss","main");
&boss = 1;
}
say("I picked up a nut!",1);
sp_active(¤t_sprite, 0);
}
========================
Now when I hit the nuttree and the nut falls and I want to pick the nut It says "I'm full! I can't pick up anything else." and my items pack is full of nuts. And the boss script is starting and I get a lot of bosses in the screen instead of one. And when I killed them I still can pick a nut.
ANd for Also make sure &boss is a global var. Do you mean the &boss I put in the S1-nut file or does it have to be in another file??????????????????????????????????????????????????????????????????????????????????????
Please help
================================
The nuttree
void main( void )
{
int &crap;
}
void talk( void )
{
say_stop("Hey, I found the Nuttree.", 1);
wait(250);
}
void hit( void )
{
&crap = scripts_used();
if (&crap > 170)
{
//don't make any more nuts, there are 165 already on the screen..)
return;
}
if(&boss == 1)
{
return
}
//lets make the nut fall down and give it a nut script
&crap = create_sprite( 158, 226, 0, 421, 23);
sp_speed(&crap, 1);
move_stop(&crap, 2, 226, 1)
sp_script(&crap, "s1-nut");
}
=======================================
s1-nut
void main( void )
{
int &boss;
sp_touch_damage(¤t_sprite, -1);
}
void touch( void )
{
int &junk = free_items();
if (&junk < 1)
{
say("I'm full! I can't pick up anything else.", 1);
return;
}
add_item("item-nut",438, 19);
if(&boss == 0)
{
external("s10-gobboss","main");
&boss = 1;
}
say("I picked up a nut!",1);
sp_active(¤t_sprite, 0);
}
========================
Now when I hit the nuttree and the nut falls and I want to pick the nut It says "I'm full! I can't pick up anything else." and my items pack is full of nuts. And the boss script is starting and I get a lot of bosses in the screen instead of one. And when I killed them I still can pick a nut.
ANd for Also make sure &boss is a global var. Do you mean the &boss I put in the S1-nut file or does it have to be in another file??????????????????????????????????????????????????????????????????????????????????????
Please help