Problem with walking monsters
When I add a monster that I've created myself they seams to prefer walking in just two directions (7 and 3), wich make them look really wierd. I noticed this while makeing the 'members of the order' in 'the bomb' too, but I didn't really care about it. So, is there any way to solve this?
Here's the monsters script if it's anything wrong with it:
Here's the monsters script if it's anything wrong with it:
//Stone worm
void main( void )
{
int &mcounter;
sp_brain(¤t_sprite, 9);
sp_speed(¤t_sprite, 1);
sp_distance(¤t_sprite, 50);
sp_timing(¤t_sprite, 33);
sp_exp(¤t_sprite, 15);
sp_base_walk(¤t_sprite, 860);
sp_base_death(¤t_sprite, -1);
sp_defense(¤t_sprite, 1);
sp_touch_damage(¤t_sprite, 5);
sp_hitpoints(¤t_sprite, 15);
preload_seq(861);
preload_seq(863);
preload_seq(867);
preload_seq(869);
preload_seq(865);
}
void hit( void )
{
playsound(29, 22050,0,¤t_sprite, 0);
sp_target(¤t_sprite, &enemy_sprite);
//lock on to the guy who just hit us
//playsound
}
void die( void )
{
int &hold = sp_editor_num(¤t_sprite);
if (&hold != 0)
editor_type(&hold, 6);
&save_x = sp_x(¤t_sprite, -1);
&save_y = sp_y(¤t_sprite, -1);
//drops
external("emake","small");
spawn("drop-w");
}
Do they actually move in 4 direction directions, and face only 7 and 3, or do they move in only directions 7 and 3? Try making them brain 10.
It's moveing in all directions but only faceinng 7 and 3, yes.
I'll try to change brain to 10 tomorrow, I'm going to bed now ;
I'll try to change brain to 10 tomorrow, I'm going to bed now ;
Same problem with brain 10.
If I use brain 16 it works, but the monster wont attack dink...
If I use brain 16 it works, but the monster wont attack dink...
Are the graphics loaded into the correct sequence slots? (861,863,867,869)
I'm sure they are, otherwise it wouldn't work with brain 16, would it?
Anyway, here is the .ini lines:
load_sequence_now graphics\stoneh\m_1- 861 150
load_sequence_now graphics\stoneh\m_3- 863 150
load_sequence_now graphics\stoneh\m_5- 865
load_sequence_now graphics\stoneh\m_7- 867 150
load_sequence_now graphics\stoneh\m_9- 869 150
Anyway, here is the .ini lines:
load_sequence_now graphics\stoneh\m_1- 861 150
load_sequence_now graphics\stoneh\m_3- 863 150
load_sequence_now graphics\stoneh\m_5- 865
load_sequence_now graphics\stoneh\m_7- 867 150
load_sequence_now graphics\stoneh\m_9- 869 150
Hmm, well, I looked at the shadows in The Bomb. I didn't notice any problem, that's pretty much how it's supposed to work.
Sprites use the **3 sequence to move down and right, and **7 to move up and left. **1 and **9 only show up when they're moing diagonally, and since brain 9 monsters targeting someone mainly move in lateral directions, those sequences don't show up a lot. If you took away the sp_target() code from the monsters' script, they should also use all their sequences more.
If you don't like how it looks, you could fiddle with the sequence numbering, eg. loading the graphics in the slots 862, 864, 866 and 868 instead.
If you don't like how it looks, you could fiddle with the sequence numbering, eg. loading the graphics in the slots 862, 864, 866 and 868 instead.










