Ticket #46120

is_action_possible(): Redundant checks for CLEAN_*

Open Date: 2022-11-27 03:18 Last Update: 2022-12-23 22:07

Reporter:
Owner:
Type:
Status:
Closed
Component:
MileStone:
Priority:
5 - Medium
Severity:
5 - Medium
Resolution:
Fixed
File:
2

Details

When is_action_possible() determines target extra for CLEAN_POLLUTION or CLEAN_FALLOUT by prev_extra_in_tile() some of the later checks are redundant (should be done only for caller-provided extras); we already know that the extra is on tile, and that it's removed by the action.

Ticket History (3/5 Histories)

2022-11-27 03:18 Updated by: cazfi
  • New Ticket "is_action_possible(): Redundant checks for CLEAN_*" created
2022-12-17 22:42 Updated by: cazfi
  • Owner Update from (None) to cazfi
  • Resolution Update from None to Accepted
  • Milestone Update from (None) to 3.0.6 (closed)
Comment

Same logic (existing code & how to fix it) applies to S3_0, though there it's not about action, but activity.

2022-12-23 22:07 Updated by: cazfi
  • Status Update from Open to Closed
  • Resolution Update from Accepted to Fixed

Edit

Please login to add comment to this ticket » Login