Slayer Bug
Hey all,
I have an endingboss slayer, but when he dies two strange things happen...
1. There is only exp given, but no money and heart. The exp is mentioned in the main void but the others in the die process..
2. The dead body of the slayer disappears after pressing space or waiting untill the sentence is finished. This is the die void:
void die( void )
{
screenlock(0);
say("Let's see if Pim is OK...", 1);
&save_x = sp_x(¤t_sprite, -1);
&save_y = sp_y(¤t_sprite, -1);
external("emake","xlarge");
int &hold = sp_editor_num(¤t_sprite);
if (&hold != 0)
editor_type(&hold, 6);
}
I hope someone can help me!
Greetings, Sjoerdje
I have an endingboss slayer, but when he dies two strange things happen...
1. There is only exp given, but no money and heart. The exp is mentioned in the main void but the others in the die process..
2. The dead body of the slayer disappears after pressing space or waiting untill the sentence is finished. This is the die void:
void die( void )
{
screenlock(0);
say("Let's see if Pim is OK...", 1);
&save_x = sp_x(¤t_sprite, -1);
&save_y = sp_y(¤t_sprite, -1);
external("emake","xlarge");
int &hold = sp_editor_num(¤t_sprite);
if (&hold != 0)
editor_type(&hold, 6);
}
I hope someone can help me!
Greetings, Sjoerdje
I tried that but that didn't matter...
I also tried it without any line, didn't matter either.
Next I tried with less Exp. Results:
You didn't go up a level so you won't have to click an atribute you want to raise. The dead slayer lies where you killed him, doesn't disappear.. But still, drops nothing...
I also tried it without any line, didn't matter either.
Next I tried with less Exp. Results:
You didn't go up a level so you won't have to click an atribute you want to raise. The dead slayer lies where you killed him, doesn't disappear.. But still, drops nothing...
Don't put anything in the main, only have a spawn script in the die that does all you want, and see if that helps (use add_exp() in the spawned script)
Or check out the seth boss script from main game to see what he did.
Or check out the seth boss script from main game to see what he did.
You silly thing, you should've mentioned that in the first post! Now I'm so mad at you....
Anyways, the screen is always redrawn when you levelup so all blood and corpses disappear. Try what SimonK said. (I dunno if putting &update_status = 0; in the die procedure would do the trick....hmm...that'd propably screw something up)
As for yer second problem, make sure that you load the globals &save_x and &save_y in main.c
Anyways, the screen is always redrawn when you levelup so all blood and corpses disappear. Try what SimonK said. (I dunno if putting &update_status = 0; in the die procedure would do the trick....hmm...that'd propably screw something up)
As for yer second problem, make sure that you load the globals &save_x and &save_y in main.c
Ah yes, I forgot to load those globals, thanks scratcher.
As for the disappearing, I'll just make sure that dink won't get too much exp
As for the disappearing, I'll just make sure that dink won't get too much exp
Um... am I missing something? Why *wouldn't* you have initialized save_x and save_y?
For some reason they aren't in the skeleton, I believe...
That's where Mike made a great job a bit crappier. Some of the graphics are missing too.
I think those graphics are intentionally missing. but it sucks anyway. that's why I never use skeleton B.
I don't know what you guys are smoking, but the skeleton b I downloaded most certainly initializes save_x and save_y. Maybe you've an old version?
I dunno. I've never noticed that myself. I just know that some of the graphics are missing.
August 18th 2004, 12:39 PM
MiloBones
Looking through the dinkvar.h file in the source, Seth assigns pointers (? My C++ is quite rusty) to a bunch of globals, like strength and lifemax and so on, but not to save_x and save_y.
This isn't relevant, but it is interesting, given the wording of main.c
This isn't relevant, but it is interesting, given the wording of main.c
Yep, but save_x and save_y is needed in (virtually) every D-Mod, because the items-spawned-when-monsters-die-script (eg. emake.c) uses save_x and save_y to place the bonuses.
August 21st 2004, 09:57 AM
MiloBones
I believe the winking blue star effect you get from an elixir uses them as well.