Greetings to everyone,this is my first post after reading so many topics as a guest.I believe
this is not mentioned before in the forums(i hope so or else....!).
(1)I 'm trying to set up 'on sight' attacks between critter types from critter scripts.
(e.g. a floater will instantly attack if see or hear or tile_distance any specific critter_pid or some of them,or all of them if possible)
Attacks that will not involve in any way obj_dude.
I searched in scripts and in game but couldn't find anything similar except
for the random encounters fighting each other but again i can't find their scripts either(i don't know how their behavior is handled.)
the simpliest example would be:
#define any_obj (PID_SHI_GUARD) or\
(PID_SHI_MALE_PEASANT) or\
(PID_SHI_FEMALE_PEASANT)
procedure critter_p_proc begin
if (obj_can_see_obj(self_obj,any_obj)) then begin
attack(any_obj);
end
end
In any way that i tried this concept(not necessary with the above example) the game crashed upon function of the script.
I 'm coming to the conclusion that this cannot happen as all game twists around the player and no 'indepedent' action can be taken outside the player.Any suggestions?
(2)my second bugging is how to override players damage or destroy procedure so the health counter will not go down when is hitted and obviously never die.
like the "Is Invulnerable????" in critter flags while critter editing in the mapper.
i cannot really uderstand vorpal rat script for a hint.
In any way thanks for reading this and sorry for the hassles...Lyer,out.
this is not mentioned before in the forums(i hope so or else....!).
(1)I 'm trying to set up 'on sight' attacks between critter types from critter scripts.
(e.g. a floater will instantly attack if see or hear or tile_distance any specific critter_pid or some of them,or all of them if possible)
Attacks that will not involve in any way obj_dude.
I searched in scripts and in game but couldn't find anything similar except
for the random encounters fighting each other but again i can't find their scripts either(i don't know how their behavior is handled.)
the simpliest example would be:
#define any_obj (PID_SHI_GUARD) or\
(PID_SHI_MALE_PEASANT) or\
(PID_SHI_FEMALE_PEASANT)
procedure critter_p_proc begin
if (obj_can_see_obj(self_obj,any_obj)) then begin
attack(any_obj);
end
end
In any way that i tried this concept(not necessary with the above example) the game crashed upon function of the script.
I 'm coming to the conclusion that this cannot happen as all game twists around the player and no 'indepedent' action can be taken outside the player.Any suggestions?
(2)my second bugging is how to override players damage or destroy procedure so the health counter will not go down when is hitted and obviously never die.
like the "Is Invulnerable????" in critter flags while critter editing in the mapper.
i cannot really uderstand vorpal rat script for a hint.
In any way thanks for reading this and sorry for the hassles...Lyer,out.