jpcsupplies / Economy_mod

Basic Economy System for Space Engineers
13 stars 12 forks source link

Collect Command Abuse #177

Closed Silverbane closed 6 years ago

Silverbane commented 6 years ago

Is there any way to restrict the /collect function to work within the trade zone from which you purchased the item? We're seeing many people spawn in at our trade station, fill their inventory with stone, buy what they want, respawn back at their base hundreds of km away and /collect there. It allows them to avoid all risk to their ships in coming to trade, circumventing a source of community interaction we were hoping to develop on the server.

As a thought, I believe that each stored transaction has a unique entry in the data file, and each trade zone has a unique identifier. If you appended the trade zone ID into the stored transaction, /collect could check for a match to the trade zone you are (or are not) in, using a similar mechanic to the checks already performed by /buy, /sell, etc., and error out/block the action if a match is not obtained.

midspace commented 6 years ago

I have new code up on our public server for testing.

midspace commented 6 years ago

jpcsupplies has published the fixes. /collect should now only work when inside the market that you bought the items in.

Previously bought items before the update can still be collected outside the market.