Jump to content

Safe Trader Inventory Cleanup Script?


DrScandalous

Recommended Posts

Obviously, you can "release" the inventory of a dynamic trader "back into the wild" by shooting them. Everyone knows that. 

 

But in a safe trader zone, you can't kill them... and they're a target destination for players who are looking to loot and bank the money. 

 

So, in the safe trader inventories, you end up with a TON of high-tier ground/air vehicles that sit there for many weeks. 

 

Does anyone know if there is a script/function in existence that takes items that have been in a trader inventory for X amount of time and automatically deletes them? This would help with the high-tier vehicles that sit there for forever, but it would also help alleviate the 2.2 billion moist towelettes, signal rounds, etc that accumulate. 

Link to comment
Share on other sites

This is definitely an issue that needs and will get attention. We all want balance and to keep the gameplay going. 

 

Some players currently 'park' their vehicles with traders for safe keeping and take the hit when buying them back.

 

That said a vehicle that is static at a traders should be repurposed. Maybe a system of distribution throughout the traders where items filter out to other traders..

Link to comment
Share on other sites

This is definitely an issue that needs and will get attention. We all want balance and to keep the gameplay going. 

 

Some players currently 'park' their vehicles with traders for safe keeping and take the hit when buying them back.

 

That said a vehicle that is static at a traders should be repurposed. Maybe a system of distribution throughout the traders where items filter out to other traders..

 

Maybe traders can share vehicle inventory? Sell a hunter at Trader "A", and it is available for purchase at all traders? Prevents "virtual garages" and re-purposes the car back into the server.

Link to comment
Share on other sites

I mean, I like it how it currently is... I think "hiving" or limiting the trader inventories would be a mistake... as it currently forces people to get out and about to look for gear they want to buy. I personally LOVE this about A3 Epoch vs. A2 Epoch... plus then you'd just have people sitting at traders and "sniping" items as soon as they become available on "the market" if you know what I mean. 

 

All I'm saying is that sometimes items just SIT in the safe traders inventories and since the NPC's can't be killed (and it's a royal pain for admins to hop on the server and "purge" the inventories manually, not to mention it might become a point of controversy on server communities) in safe zones, it'd be nice to have some sort of a "decay" timer on items... that's all. 

Link to comment
Share on other sites

And yes... STACKING the item inventories would be amazing (if it's possible). A++, +1, FULL support on that!!!!

 

And... I hate to ask... is it possible to PLEASE get the description panes widened so that you can see the full item description? (IE: Sound suppressor descriptions, 6.5mm caseless ammo, etc etc where you can't see the full description of the item and it can be confused/mixed up)

Link to comment
Share on other sites

I mean, I like it how it currently is... I think "hiving" or limiting the trader inventories would be a mistake... as it currently forces people to get out and about to look for gear they want to buy. I personally LOVE this about A3 Epoch vs. A2 Epoch... plus then you'd just have people sitting at traders and "sniping" items as soon as they become available on "the market" if you know what I mean. 

 

All I'm saying is that sometimes items just SIT in the safe traders inventories and since the NPC's can't be killed (and it's a royal pain for admins to hop on the server and "purge" the inventories manually, not to mention it might become a point of controversy on server communities) in safe zones, it'd be nice to have some sort of a "decay" timer on items... that's all. 

Ya i agree.

 

In my opinion i wouldn't have traders at the spawn point period, but if there are going to be traders at the spawn point, maybe possible to put a cleanup script like you said. Rather then cleaning up items in the inventory, is it possible and viable to maybe "renew" (auto kill and respawn) that spawn point trader after so many restarts? Let's say after 10-20 restarts, that specific trader would be killed and respawned with wiped inventory. You could have it cycle through each spawn trader so not all spawn traders are renewed at once. 

 

I am an idiot when it comes to scripts, but i think that the script would be too complex no? how would it determine which items to delete or move? Would it determine when an item was sold to that trader? What and how could you figure out the perfect time frame of how long that item could be stored there?

 

Any direction to try and clean up the trader's inventory at spawn points, i give a major +1 on. Hope with everyone's opinions there is a viable solution that will work perfectly.

Link to comment
Share on other sites

Well, the previously mentioned option of nesting/stacking the item inventories (I think) would be a HUGE help if it's technically feasable, for sure. I mean, I love 9mm 15 round clips as much as the next guy, but.... yeah. Or maybe have a set max quantity of an item, since I don't think there are many items that require buying 20/30 of at a time, but that's a whole 'nother thread, lol. 

 

As I'm not a coder as well, I'd imagine that coding the NPC's to wipe their inventory at set intervals wouldn't be impossible at all... I'm guessing that they're not THAT different from the current dynamic traders who's inventories get wiped upon death, it's only the safe zone that protects them from it happening currently. Maybe a timer that performs a kill function/respawn function during the restart? Once again... pure speculation here. 

Link to comment
Share on other sites

Would be nice if there was an option to remove the traders at the spawns so players could only trade at the individual traders around the map.

 

spawnzonetraders = 0;

 

?

 

I think when that decision is made you might as well do away with the safe zones/safe spawn trader points entirely and go to the random/dynamic spawn points that drop you anywhere on the map... 

 

Call me a bambi if you'd like, but I'm not so much a fan of that. Just my personal preference, though. Everyone differs. 

Link to comment
Share on other sites

I think when that decision is made you might as well do away with the safe zones/safe spawn trader points entirely and go to the random/dynamic spawn points that drop you anywhere on the map... 

 

Call me a bambi if you'd like, but I'm not so much a fan of that. Just my personal preference, though. Everyone differs. 

 

That's exactly what I am proposing. A server variable that could be set if the server owner doesn't want traders in the spawn points. Who actually uses those traders anyway? I'll be damned if I'm going to go there and sell/buy stuff.

Link to comment
Share on other sites

That's exactly what I am proposing. A server variable that could be set if the server owner doesn't want traders in the spawn points. Who actually uses those traders anyway? I'll be damned if I'm going to go there and sell/buy stuff.

The spawn points usually have the most items compared to any other trader (on Mells House anyway).

Link to comment
Share on other sites

That's why I go there too... not for the safe zone, but because there is usually 2-3x as many items at those traders than anywhere else. 

I think it's about 50/50. You ask some people why they go there, they say "well it has the most amount of items, so we are almost guaranteed to find what we need." . Then you ask others and they say "We go there because we know we can't get shot while trading.".

 

The point it becomes a pain in my but is the amount of vehicles some of these traders have. I'd like to see those vehicles put back on the map. Another pain is the traffic of people that go there, then there is battles in which innocent spawns stumble upon. The rage from new spawn players gets intense.

Link to comment
Share on other sites

Have you tried using the admin tool looking at them and just hitting delete? they will respawn at reset would that not act as a Death to the safezone trader?

 

give me a min and i'll test it out

 

Update: well didn't go as planned i teleported a Vehicle to the NPC it just happen to be right on top of him making the Vehicle blow up for a safe zone that NPC is deadd lol

Link to comment
Share on other sites

This is a problem on populated servers, our server the traders had 100s of items, i am not sure but vehicles seem to be getting trapped in there and not being spawned any more which was causing a vehicle shortage.

 

The semi manual method i used to clean them was ...

 

BACKUP DB FIRST

 

1. Install REDIS Desktop Manager

2. connect to DB when server offline

2. Manually update each trader ( AI_ITEMS --> 1 --> AI_ITEMS:1:XX ) to [[],[]] to purge them.

 

There is also a redis command line client also called redis_cli.exe you could also do it in this.

Link to comment
Share on other sites

Preference for me would be to have the items filtered out to the dynamic traders with a cap on certain items or a variable price based on quantity and demand like there would be in real life. No trader would keep purchasing the same item over and over 50 times for the same price if he didn't sell any.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...