Page MenuHomeFeedback Tracker

Feature Request // Delete item from map
Reviewed, NormalPublic

Description

Due to an incorrect type definition in the types.xml, the map was "flooded" with an item. The problem was something like the following type definition.

 "types.xml"
+------------------------------------------------
|
| <type name="FAL">
|     <nominal>4</nominal>
|     <lifetime>28800</lifetime>
|     <restock>0</restock>
|     <min>2</min>
|     <quantmin>-1</quantmin>
|     <quantmax>-1</quantmax>
|     <cost>100</cost>
|     <flags count_in_cargo="1" count_in_hoarder="0" count_in_map="0" count_in_player="0" crafted="0" deloot="0"/>
|     <category name="weapons"/>
|     <usage name="Military"/>
|     <value name="Tier3"/>
|     <value name="Tier4"/>
| </type>
|
+------------------------------------------------

The problem was that count_in_map="0" was set. The CE only counted the item in cargo and always came up with 0, the nominal limit is then ignored. When the error was noticed, more than 400 FAL were spread across the map.

Question:
Is there a way to completely remove the item from the map by specifying it in types.xml or elsewhere in the configuration files?

If not: would it be possible to include an additional flag in types.xml - e.g. ceDelete="1" - which ensures that the item is completely removed from the map when the server is started and after the Central Economy has been fully initialized?

After removing the item, the admin must stop the server, reset the "ceDelete" to 0 and then start the server again.

Example / Steps:

  1. Stop server
  1. Set the ceDelete flag to "1" for the item or items that should be completely removed from the map
    "types.xml"
    +------------------------------------------------
    |
    | <type name="FAL">
    |     <nominal>4</nominal>
    |     <lifetime>28800</lifetime>
    |     <restock>0</restock>
    |     <min>2</min>
    |     <quantmin>-1</quantmin>
    |     <quantmax>-1</quantmax>
    |     <cost>100</cost>
+++ |     <flags ceDelete="1" count_in_cargo="1" count_in_hoarder="0" count_in_map="1" count_in_player="0" crafted="0" deloot="0"/>
    |     <category name="weapons"/>
    |     <usage name="Military"/>
    |     <value name="Tier3"/>
    |     <value name="Tier4"/>
    | </type>
    |
    +------------------------------------------------
  1. Start the server and wait for the item to be completely deleted (ideally logging in an RPT file)
  1. Stop server
  1. Set the ceDelete flag back to "0".
     "types.xml"
    +------------------------------------------------
    |
    | <type name="FAL">
    |     <nominal>4</nominal>
    |     <lifetime>28800</lifetime>
    |     <restock>0</restock>
    |     <min>2</min>
    |     <quantmin>-1</quantmin>
    |     <quantmax>-1</quantmax>
    |     <cost>100</cost>
--- |     <flags ceDelete="0" count_in_cargo="1" count_in_hoarder="0" count_in_map="1" count_in_player="0" crafted="0" deloot="0"/>
    |     <category name="weapons"/>
    |     <usage name="Military"/>
    |     <value name="Tier3"/>
    |     <value name="Tier4"/>
    | </type>
    |
    +------------------------------------------------
  1. Start server

Details

Severity
Feature
Resolution
Open
Reproducibility
Always
Operating System
Windows 10 x64
Category
Config

Event Timeline

Geez changed the task status from New to Reviewed.Aug 31 2022, 3:56 PM