Mod Junk Dealers/Vendors?

Enferno

New Member
Joined
Oct 7, 2021
Messages
19
Hi guys, I've been trying to figure out how to mod junk vendors on my private server. I've searched for 2 days now and found a few mentions on post here and there, but nothing that pointed to "where" or "how" to mod them.
Can anyone please just point me to the file(s) to change so that I can either:

A: Merge ALL the junk vendors together so that they ALL buy the items at once. I.E. No matter what junk vendor you go to they'll all buy every junk vendor item, not just a few items here and there.
B: Make a junk vendor OR the player creation terminal (blue frog) have a "SELL ALL" button to sell everything at once.
C: Create my own vendor for selling whatever I put into the .lua file.

Thanks to anyone with any information to help direct me!!

-- What I've done so far --
  1. I've done a full file search in the MMOCoreORB and looked at the files to do with "Junk_Dealers / junkdealers / junkshop" and I don't see anything on how to actually alter what they buy.
  2. I've searched through the .tre files using the "SIE" tool and I don't see anything to actually modify what they sell. I only see the files under mobile to change their gender / race / appearances.
Here are a few post that I found with a bit of information, but some are just "suggestions" and others are old and I can't find any information on how to do it.

  1. https://swgbeyond.com/threads/qol-changes.161/page-2
  2. https://modthegalaxy.com/index.php?threads/legend-of-hondo-my-collection-of-server-mods.473/
  3. https://www.swgemu.com/forums/showthread.php?t=198677 -- This one "touched" on it a bit, but doesn't mention "how" they did it. If you'll look at the section "Events/Dungeons/Theme Parks/Quests" towards the bottom you'll see "Added the heralds for the geonosian lab (including the one that also acts as a junk dealer for the geo relics)" < --- How do I do this?
 

N. Poulsen

New Member
Joined
Sep 2, 2010
Messages
4
To get all junk dealers to accept all junk items, edit line 65 of this file: https://github.com/TheAnswer/Core3/blob/unstable/MMOCoreORB/bin/scripts/screenplays/junk_dealer/junk_dealer.lua

From:
Code:
if tano:getJunkDealerNeeded() & dealerNum > 0 and tano:getCraftersName() == "" and not tano:isBroken() and not tano:isSliced() and not tano:isNoTrade() and sceno:getContainerObjectsSize() == 0 then
To:
Code:
if tano:getJunkDealerNeeded() > 0 and tano:getCraftersName() == "" and not tano:isBroken() and not tano:isSliced() and not tano:isNoTrade() and sceno:getContainerObjectsSize() == 0 then
You can then also comment out lines 53-57 if you wish.

New junk items are added when you create the loot items, look here for an example: https://github.com/TheAnswer/Core3/blob/unstable/MMOCoreORB/bin/scripts/loot/items/armor/bh_armor_bicep_l.lua
 

Enferno

New Member
Joined
Oct 7, 2021
Messages
19
Thank you very very much! I've been trying and trying with mostly "breaking" my server! :)

Ok, after further looking into the "loot" scripts, anything that is listed under "items" will sell to the junk vendors now?

EDIT Nevermind! I see, it's the ones with:

junkDealerTypeNeeded = JUNKGENERIC,
junkMinValue = 55,
junkMaxValue = 110
 
Last edited:
Top Bottom