Ticket #47463

action_is_hostile() rework

Date d'ouverture: 2023-02-20 19:51 Dernière mise à jour: 2023-03-04 21:29

Rapporteur:
Propriétaire:
Type:
État:
Atteints
Composant:
Jalon:
Priorité:
5 - moyen
Sévérité:
5 - moyen
Résolution:
Fixed
Fichier:
1

Détails

action_is_hostile() has several aspects I'd like to improve.

- It lives in unittype.c, even when it's about actions
- It's another massive switch - case, based on actres. Should be turned to a quick array lookup
- Type of the parameter needs to be checked. Both actres pointer and action pointer would likely be better than current action id

Ticket History (3/5 Histories)

2023-02-20 19:51 Updated by: cazfi
  • New Ticket "action_is_hostile() rework" created
2023-02-22 08:46 Updated by: cazfi
Commentaire

Better to implement on top of #47464 than before it.

2023-03-02 20:29 Updated by: cazfi
  • Propriétaire Update from (Aucun) to cazfi
  • Résolution Update from Aucun to Accepted
2023-03-04 21:29 Updated by: cazfi
  • État Update from Ouvert to Atteints
  • Résolution Update from Accepted to Fixed

Modifier

Please login to add comment to this ticket » Connexion