Reply to Re: I love photoshop.
If you don't have an account, just leave the password field blank.
How do I script a chest with 100 gold in it, and a longsword? No tutorial I found has anything about a chest.
You'll want to do several things for this.
void hit(void)
{
freeze(1);
wait(20);
//play the chest animation by changing the brain, base_walk, and speed of the sprite.
wait(20);
//create the gold sprite and use sp_script on it.
//add the sword to the inventory.
say_stop("LOOK AT THE SIZE OF THIS POKING STICK!", 1);
wait(50);
unfreeze(1);
//if you're using a global declare it now.
}
For the script you make to assign to the gold:
void main(void)
{
sp_touch_damage(¤t_sprite, -1);
//make it hard(giggity)
}
void touch(void)
{
&gold += 100;
// then use a nodraw and an sp_active
}
So your scripts should be something like those. I'd suggest playing around with each thing step by step. Like just start by trying to make sure the animation will play.
Good Luck.
You'll want to do several things for this.
void hit(void)
{
freeze(1);
wait(20);
//play the chest animation by changing the brain, base_walk, and speed of the sprite.
wait(20);
//create the gold sprite and use sp_script on it.
//add the sword to the inventory.
say_stop("LOOK AT THE SIZE OF THIS POKING STICK!", 1);
wait(50);
unfreeze(1);
//if you're using a global declare it now.
}
For the script you make to assign to the gold:
void main(void)
{
sp_touch_damage(¤t_sprite, -1);
//make it hard(giggity)
}
void touch(void)
{
&gold += 100;
// then use a nodraw and an sp_active
}
So your scripts should be something like those. I'd suggest playing around with each thing step by step. Like just start by trying to make sure the animation will play.
Good Luck.