Home » PLAYER'S HQ 1.13 » v1.13 General Gameplay Talk » Just when you thought it was safe in the forums...
|
|
|
|
|
|
|
|
|
Re: Just when you thought it was safe in the forums...[message #271046]
|
Mon, 24 January 2011 07:42
|
|
SpaceViking |
|
Messages:751
Registered:January 2004 Location: Rochester, Minnesota, USA |
|
|
The warning is there to keep people from messing with the file. A lot of the potential settings are actually never used by any of the current merchants but there is code to do something with them.
There is still some code specific to certain merchants that I didn't remove. Because of that you can't change the basic type of the merchant: buys only, buys and sells, sells only, or repairs. I was going to work out a way to change that and get rid of the code but I never got back to it.
What I was thinking of is that if the merchant had only a BUYCOSTMODIFIER then he would be a BUYONLY merchant. If he had only a SELLCOSTMODIFIER then he would be a SELLONLY merchant. If he had both then he'd be a BUYSELL merchant. If there was a repair cost then he'd be a REPAIRONLY merchant. Those choices are waht determine how you can interact and there's currently nothing to (for instance) allow a merchant to sell and repair.
Here is the default data of the merchants:
//Buying Selling Merc ID# Type Initial Flags
//Price Price Of Cash
//Modifier Modifier Dealer
/* Tony */ { 0.75f, 1.25f, TONY, ARMS_DEALER_BUYS_SELLS, 15000, ARMS_DEALER_SOME_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 15000, 15000, 0, 1, 10, 1, 10, 2, 3, false, false },
/* Franz Hinkle */ { 1.0f, 1.5f, FRANZ, ARMS_DEALER_BUYS_SELLS, 5000, ARMS_DEALER_SOME_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 5000, 5000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Keith Hemps */ { 0.75f, 1.0f, KEITH, ARMS_DEALER_BUYS_SELLS, 1500, ARMS_DEALER_ONLY_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 1500, 1500, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Jake Cameron */ { 0.8f, 1.1f, JAKE, ARMS_DEALER_BUYS_SELLS, 2500, ARMS_DEALER_ONLY_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 2500, 2500, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Gabby Mulnick*/ { 1.0f, 1.0f, GABBY, ARMS_DEALER_BUYS_SELLS, 3000, ARMS_DEALER_GIVES_CHANGE , 3000, 3000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Devin Connell*/ { 0.75f, 1.25f, DEVIN, ARMS_DEALER_SELLS_ONLY, 5000, ARMS_DEALER_GIVES_CHANGE , 5000, 5000, 0, 3, 10, 0, 10, 2, 3, false, false },
/* Howard Filmore*/ { 1.0f, 1.0f, HOWARD, ARMS_DEALER_SELLS_ONLY, 3000, ARMS_DEALER_GIVES_CHANGE , 3000, 3000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Sam Rozen */ { 1.0f, 1.0f, SAM, ARMS_DEALER_SELLS_ONLY, 3000, ARMS_DEALER_GIVES_CHANGE , 3000, 3000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Frank */ { 1.0f, 1.0f, FRANK, ARMS_DEALER_SELLS_ONLY, 500, ARMS_DEALER_ACCEPTS_GIFTS , 500, 500, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 1 */ { 1.0f, 1.0f, HERVE, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 2 */ { 1.0f, 1.0f, PETER, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 3 */ { 1.0f, 1.0f, ALBERTO, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 4 */ { 1.0f, 1.0f, CARLO, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Micky O'Brien*/ { 1.0f, 1.4f, MICKY, ARMS_DEALER_BUYS_ONLY, 10000, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 10000, 10000, 0, 1, 10, 1, 10, 1, 2, false, true },
//Repair Repair
//Speed Cost
/* Arnie Brunzwell*/ { 0.1f, 0.8f, ARNIE, ARMS_DEALER_REPAIRS, 1500, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 1500, 1500, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Fredo */ { 0.6f, 0.6f, FREDO, ARMS_DEALER_REPAIRS, 1000, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 1000, 1000, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Perko */ { 1.0f, 0.4f, PERKO, ARMS_DEALER_REPAIRS, 1000, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 1000, 1000, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Elgin */ { 1.0f, 1.0f, DRUGGIST, ARMS_DEALER_SELLS_ONLY, 500, ARMS_DEALER_ACCEPTS_GIFTS , 500, 500, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Manny */ { 1.0f, 1.0f, MANNY, ARMS_DEALER_SELLS_ONLY, 500, ARMS_DEALER_ACCEPTS_GIFTS , 500, 500, 0, 1, 10, 1, 10, 1, 2, false, true },
As you can see most of the "flags" aren't used. Some of them are obsolete now that dealers have specific lists of items they carry. But others have an effect in how their inventory is stocked (like the AMMO one)
Tony's XML for the flags:
Any idea what the gift thing is for? In the code it is handled as a "bribe" but it only seems to do something for Frank.
[Updated on: Mon, 24 January 2011 07:48] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
|
Re: Just when you thought it was safe in the forums...[message #273522]
|
Mon, 14 February 2011 03:31
|
|
Wil473 |
|
Messages:2815
Registered:September 2004 Location: Canada |
|
|
Space Viking, I am seeing some odd buying behaviour with Betty (Keith NPC ID/merchant stuff) and Franz when I activate the extra merchant settings to reassign merchant functions. Oddly the two affected merchants do not have any of the extended tags added to their Merchant Inventory XML's.
It was originally reported that since UC-1.13 v3 was released last month that Betty stopped buying break lights. This is despite having the proper entry in the Keith merchant inventory XML, and also Keith in the stock Data-1.13 campaign buying them under the same r4057 .exe in Tais' final SCI (though I noticed that in Data-1.13, Keith was buying break lights without having them defined in the XML). The following were tried without success:
- reordering the XML inventory numerically by the item index
- adding the extra merchant tags to the Keith merchant XML explicitly pointing to the default 2: Keith Hemps and 147
- non-zero optimum inventory of break lights in the Keith merchant XML, this one led to Betty selling Break lights for $1.00, but still not buying them. Also realized that a bunch of other items on sale were being sold, but not being bought. It seems that the XML is forcing these items into inventory for sale by the merchant, but some internal and more restrictive rules were making these items "illegal" leading to refusal to buy, and appearing for sale for only $1.00.
It was later noticed that Franz was doing the same thing, but with some, but strangely not all weapon sights. ie. FLIR Sight for $1.00. The expected behaviour, from past UC-1.13 mods, is that Franz happily bought everything assigned in the XML.
What finally got Betty to buy break lights was to purge all modified merchant XML's (renaming the folders) so that the game would fall back on Data-1.13 for Merchant XML's. I could not get away with simply deleting the Keith merchant ID from the mod's Data folder, but I had to effectively purge all of them. This has me suspicious that the strange behaviour from Betty and Franz is related to those extra merchant settings I started using in UC-1.13v3.
Tony, merchants that sell only (Devin and bartenders), as well as NPC assigned the Gabby merchant traits seem un-affected, though in my own testing I haven't gotten around to systematically selling to Tony and Gabby every single item they are supposed to buy. I have also not tried selling blood cat parts to Micky.
At present the two options I see are:
1) leave as is and advise people to try liberating factories for income in-game.
2) Rebuild all merchant XML's from the ones in Data-1.13, not use the the extended merchant capabilities.
Thought I should bring up the issue with you before proceeding. Any input on this matter would be greatly appreciated.
[Updated on: Mon, 14 February 2011 03:46] by Moderator Report message to a moderator
|
|
|
|
|
Re: Just when you thought it was safe in the forums...[message #273533]
|
Mon, 14 February 2011 05:37
|
|
SpaceViking |
|
Messages:751
Registered:January 2004 Location: Rochester, Minnesota, USA |
|
|
/* Tony */ { 0.75f, 1.25f, TONY, ARMS_DEALER_BUYS_SELLS, 15000, ARMS_DEALER_SOME_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 15000, 15000, 0, 1, 10, 1, 10, 2, 3, false, false },
/* Franz Hinkle */ { 1.0f, 1.5f, FRANZ, ARMS_DEALER_BUYS_SELLS, 5000, ARMS_DEALER_SOME_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 5000, 5000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Keith Hemps */ { 0.75f, 1.0f, KEITH, ARMS_DEALER_BUYS_SELLS, 1500, ARMS_DEALER_ONLY_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 1500, 1500, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Jake Cameron */ { 0.8f, 1.1f, JAKE, ARMS_DEALER_BUYS_SELLS, 2500, ARMS_DEALER_ONLY_USED_ITEMS | ARMS_DEALER_GIVES_CHANGE, 2500, 2500, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Gabby Mulnick*/ { 1.0f, 1.0f, GABBY, ARMS_DEALER_BUYS_SELLS, 3000, ARMS_DEALER_GIVES_CHANGE , 3000, 3000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Devin Connell*/ { 0.75f, 1.25f, DEVIN, ARMS_DEALER_SELLS_ONLY, 5000, ARMS_DEALER_GIVES_CHANGE , 5000, 5000, 0, 3, 10, 0, 10, 2, 3, false, false },
/* Howard Filmore*/ { 1.0f, 1.0f, HOWARD, ARMS_DEALER_SELLS_ONLY, 3000, ARMS_DEALER_GIVES_CHANGE , 3000, 3000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Sam Rozen */ { 1.0f, 1.0f, SAM, ARMS_DEALER_SELLS_ONLY, 3000, ARMS_DEALER_GIVES_CHANGE , 3000, 3000, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Frank */ { 1.0f, 1.0f, FRANK, ARMS_DEALER_SELLS_ONLY, 500, ARMS_DEALER_ACCEPTS_GIFTS , 500, 500, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 1 */ { 1.0f, 1.0f, HERVE, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 2 */ { 1.0f, 1.0f, PETER, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 3 */ { 1.0f, 1.0f, ALBERTO, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Bar Bro 4 */ { 1.0f, 1.0f, CARLO, ARMS_DEALER_SELLS_ONLY, 250, ARMS_DEALER_ACCEPTS_GIFTS , 250, 250, 0, 1, 10, 0, 100, 1, 2, false, true },
/* Micky O'Brien*/ { 1.0f, 1.4f, MICKY, ARMS_DEALER_BUYS_ONLY, 10000, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 10000, 10000, 0, 1, 10, 1, 10, 1, 2, false, true },
//Repair Repair
//Speed Cost
/* Arnie Brunzwell*/{ 0.1f, 0.8f, ARNIE, ARMS_DEALER_REPAIRS, 1500, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 1500, 1500, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Fredo */ { 0.6f, 0.6f, FREDO, ARMS_DEALER_REPAIRS, 1000, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 1000, 1000, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Perko */ { 1.0f, 0.4f, PERKO, ARMS_DEALER_REPAIRS, 1000, ARMS_DEALER_HAS_NO_INVENTORY | ARMS_DEALER_GIVES_CHANGE, 1000, 1000, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Elgin */ { 1.0f, 1.0f, DRUGGIST, ARMS_DEALER_SELLS_ONLY, 500, ARMS_DEALER_ACCEPTS_GIFTS , 500, 500, 0, 1, 10, 1, 10, 1, 2, false, true },
/* Manny */ { 1.0f, 1.0f, MANNY, ARMS_DEALER_SELLS_ONLY, 500, ARMS_DEALER_ACCEPTS_GIFTS , 500, 500, 0, 1, 10, 1, 10, 1, 2, false, true },
Those are the default settings. The ARMS_DEALER_xxxx ones are dangerous to set other than the few used above. I am not sure how they work and, as you can see, most of them are not used currently.
Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
Re: Just when you thought it was safe in the forums...[message #273567]
|
Mon, 14 February 2011 17:14
|
|
SpaceViking |
|
Messages:751
Registered:January 2004 Location: Rochester, Minnesota, USA |
|
|
The "new" stuff...
You can change how much they charge above normal prices (or pay), how much money they have and how often it regenerates, how they determine their inventory from the game progress, and (dangerously) some of the flags that determine their behavior (like do they give change or carry used items).
You can't change the basic type of a dealer (buys, sells, buy/sells, or repairs) right now because the game code depends on (for instance) Tony both buying and selling things. I am going to relax this restriction because for a lot of the dealers it doesn't matter.
The "old" stuff allows you to determine which items they potentially have in their inventory.
[Updated on: Mon, 14 February 2011 17:15] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
Re: Just when you thought it was safe in the forums...[message #273648]
|
Wed, 16 February 2011 00:59
|
|
Wil473 |
|
Messages:2815
Registered:September 2004 Location: Canada |
|
|
In original Urban Chaos, and UC-1.13, his NPC number's appearance does not appear to be Sci-fi quest related. The character slot is used by the one bartender, other than Frank, that does sell stuff (found in C13).
As far as what is triggering the weird behaviour, it is not his appearance selling drinks. So off the top of my head it could be:
- sheer number of items in the list
- item class, the bugged files had Gabby buying and selling guns, ammo, vests, LBE's, everything. I didn't think anything was up because he was buying and selling everything as expected from the XML.
- this specific XML being assigned to the wrong NPC EDIT: this was dis-proven last night when it all broke without reassigning any merchants to different NPC's.
When I have time to do some more testing, I'll start with the easy one, item class, and systematically add an item from each item class till Betty and Franz stop buying stuff they normally should buy.
Right now I seem to be getting away with reassignment of the Bartender (sell only) XML's.
[Updated on: Wed, 16 February 2011 01:02] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
Re: Just when you thought it was safe in the forums...[message #273656]
|
Wed, 16 February 2011 01:24
|
|
SpaceViking |
|
Messages:751
Registered:January 2004 Location: Rochester, Minnesota, USA |
|
|
Oh, hey, Gabby is forced to carry some inventory in the code. I ran across that.
Oops, it wasn't Gabby but Sam. Franz also gets the video camera and Jake gets fuel. The bar guys get liquor and Tony gets a bunch of stuff.
BOOLEAN AdjustCertainDealersInventory( )
{
//Adjust Tony's items (this restocks *instantly* 1/day, doesn't use the reorder system)
GuaranteeAtLeastOneItemOfType( ARMS_DEALER_TONY, ARMS_DEALER_BIG_GUNS );
LimitArmsDealersInventory( ARMS_DEALER_TONY, ARMS_DEALER_BIG_GUNS, 2 );
LimitArmsDealersInventory( ARMS_DEALER_TONY, ARMS_DEALER_HANDGUNCLASS, 3 );
LimitArmsDealersInventory( ARMS_DEALER_TONY, ARMS_DEALER_AMMO, 8 );
//Adjust all bartenders' alcohol levels to a minimum
GuaranteeMinimumAlcohol( ARMS_DEALER_FRANK );
GuaranteeMinimumAlcohol( ARMS_DEALER_BAR_BRO_1 );
GuaranteeMinimumAlcohol( ARMS_DEALER_BAR_BRO_2 );
GuaranteeMinimumAlcohol( ARMS_DEALER_BAR_BRO_3 );
GuaranteeMinimumAlcohol( ARMS_DEALER_BAR_BRO_4 );
GuaranteeMinimumAlcohol( ARMS_DEALER_ELGIN );
GuaranteeMinimumAlcohol( ARMS_DEALER_MANNY );
//make sure Sam (hardware guy) has at least one empty jar
GuaranteeAtLeastXItemsOfIndex( ARMS_DEALER_SAM, JAR, 1 );
if ( CheckFact( FACT_ESTONI_REFUELLING_POSSIBLE, 0 ) )
{
// gas is restocked regularly, unlike most items
GuaranteeAtLeastXItemsOfIndex( ARMS_DEALER_JAKE, GAS_CAN, ( UINT8 ) ( 4 + Random( 3 ) ) );
}
//If the player hasn't bought a video camera from Franz yet, make sure Franz has one to sell
if( !( gArmsDealerStatus[ ARMS_DEALER_FRANZ ].ubSpecificDealerFlags & ARMS_DEALER_FLAG__FRANZ_HAS_SOLD_VIDEO_CAMERA_TO_PLAYER ) )
{
GuaranteeAtLeastXItemsOfIndex( ARMS_DEALER_FRANZ, VIDEO_CAMERA, 1 );
}
return( TRUE );
}
Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Thu Apr 25 23:31:27 GMT+3 2024
Total time taken to generate the page: 0.02088 seconds
|