I have these dummy entities that should be attacked just by my turrets, nothing else. So I've defined a trigger_target_type and set it as the only value in entity.trigger_target_mask, my turrets' attack_target_mask, and all other turrets' (ammo-turret, fluid-turret, electric-turret) ignore_target_mask. This works as expected -- insofar as just my turrets will attack the dummies while they are ignored by all other ammo, fluid, and electric turrets.
However, there are other things in the game that can shoot: e.g. artillery-turrets, cars, or active-defense-equipment. These prototypes don't have attack_target_mask and ignore_target_mask. But artillery-turrets have "gun" (name of a gun prototype) and cars have "guns" (an array of names of gun prototypes). Both data.raw.gun and data.raw["active-defense-equipment"] have attack_parameters, which may contain ammo_type -- and ammo_type has the property action.trigger_target_mask.
According to the description of TriggerItem, the default of trigger_target_mask is "everything". It wouldn't make sense that you can shoot at ammo, so I assumed that it would contain the names of trigger_target_types the ammo is allowed to shoot at. But apparently, this doesn't work: I've removed my dummies' trigger_target_type from ammo_type.action.trigger_target_mask of all ammo types, but cars, artillery turrets etc. still shoot at the dummies. How can I prevent this?
Target masks again
Place to get help with not working mods / modding interface.
Target masks again
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!
Jump to
- General
- ↳ Releases
- ↳ News
- ↳ General discussion
- ↳ Multiplayer
- ↳ Find Servers / Tools / Guides
- ↳ Show your Creations
- ↳ Videos
- ↳ Combinator Creations
- ↳ Mechanical Throughput Magic (circuit-free)
- ↳ Railway Setups
- ↳ Energy Production
- ↳ Medium/Big/Gigantic Sized Structures
- ↳ Fan Art
- ↳ Gameplay Help
- ↳ Spread the Word
- ↳ Off topic
- ↳ This Forum
- ↳ Celebration Party
- Support
- ↳ Gameplay Help
- ↳ Discover Factorio Wiki
- ↳ Discover Others Creations
- ↳ Discover Mods
- ↳ Discover Tools Around Factorio
- ↳ Technical Help
- ↳ Bug Reports
- ↳ Resolved for the next release
- ↳ Fixed for 2.0
- ↳ Assigned
- ↳ Not a bug
- ↳ Pending
- ↳ 1 / 0 magic
- ↳ Duplicates
- ↳ Minor issues
- ↳ Desyncs with mods
- ↳ Won't fix.
- ↳ Resolved Problems and Bugs
- Factorio Direction
- ↳ Ideas and Suggestions
- ↳ Outdated/Not implemented
- ↳ Frequently Suggested / Link Collections
- ↳ Implemented Suggestions
- ↳ Implemented in 2.0
- ↳ Development Proposals
- ↳ Balancing
- Contributions
- ↳ Mods
- ↳ Download mods
- ↳ Mod portal Discussion
- ↳ Mods
- ↳ Mod Packs / Libs / Special Interest
- ↳ 5dim's mod
- ↳ Angels Mods
- ↳ Atomic Power
- ↳ Bob's mods
- ↳ DyWorld
- ↳ F.A.R.L
- ↳ Fentus Challenge & Tool Mods
- ↳ Logistic Train Network
- ↳ MoMods
- ↳ Reika's Mods
- ↳ Resource Spawner Overhaul
- ↳ Yuoki Industries
- ↳ PyMods
- ↳ Questions, reviews and ratings
- ↳ Modding Discussions
- ↳ Modding discussion
- ↳ Modding help
- ↳ Ideas and Requests For Mods
- ↳ Modding interface requests
- ↳ Implemented mod requests
- ↳ Implemented for 2.0
- ↳ Already exists
- ↳ Won't implement
- ↳ Documentation Improvement Requests
- ↳ Resolved Requests
- ↳ Development tools
- ↳ Tools
- ↳ Mod and installation managers
- ↳ Cheatsheets / Calculators / Viewers
- ↳ Development tools
- ↳ Special interest mods and libraries
- ↳ Modding Development
- ↳ Multiplayer / Dedicated Server
- ↳ Multiplayer Board
- ↳ Archive
- ↳ Maps and Scenarios
- ↳ Translations
- ↳ Texture Packs
- ↳ Fan Art
- ↳ Wiki Talk
- ↳ To be sorted
- ↳ Campaign / Scenario suggestions