by FDARI » Sun Apr 03, 2011 2:46 pm
Possible solutions for filtering non-monsters:
1 - New flag: JLOSF_MONSTERONLY.
a) As a late addition to this code submission
b) As a subsequent code submission
2 - New action function in separate code submission: A_JumpIfSet(string FLAG, string|int STATE, int checkactor = AAPTR_DEFAULT)
3 - Making both JLOSF_TEAMNOJUMP and JLOSF_ALLYNOJUMP implicitly verify that the target is a monster.
The second idea has a ring of wfds to it, but is probably quite easy to implement, and covers the requested feature (in an extra line of decorate) and may be applied to other uses. If the second way is viable, I don't think I'll write the first one, but if the second is not viable, I too feel the need for a monster-check.
The third idea is somewhat logical, but quite inflexible.
I haven't checked what players have in their ISMONSTER-setting. The WIKI-decorate does not add the flag, and the engine usually doesn't care, when it already knows it is a player. With JLOSF_MONSTERONLY, the player-designation makes a difference.
If you want it to include players, perhaps it needs to be JLOSF_COMBATANTONLY (ugly word, but you get the gist).
Possible solutions for filtering non-monsters:
1 - New flag: JLOSF_MONSTERONLY.
a) As a late addition to this code submission
b) As a subsequent code submission
2 - New action function in separate code submission: A_JumpIfSet(string FLAG, string|int STATE, int checkactor = AAPTR_DEFAULT)
3 - Making both JLOSF_TEAMNOJUMP and JLOSF_ALLYNOJUMP implicitly verify that the target is a monster.
The second idea has a ring of wfds to it, but is probably quite easy to implement, and covers the requested feature (in an extra line of decorate) and may be applied to other uses. If the second way is viable, I don't think I'll write the first one, but if the second is not viable, I too feel the need for a monster-check.
The third idea is somewhat logical, but quite inflexible.
I haven't checked what players have in their ISMONSTER-setting. The WIKI-decorate does not add the flag, and the engine usually doesn't care, when it already knows it is a player. With JLOSF_MONSTERONLY, the player-designation makes a difference.
If you want it to include players, perhaps it needs to be JLOSF_COMBATANTONLY (ugly word, but you get the gist).