Author Topic: Script-Modify Item Base Cost?  (Read 1043 times)

Legacy_Lightfoot8

  • Hero Member
  • *****
  • Posts: 4797
  • Karma: +0/-0
Script-Modify Item Base Cost?
« Reply #15 on: November 07, 2010, 12:02:52 am »


               

AndarianTD wrote...

Hmm... The entries are already there in the file, but there's a "ClientLoad" column with a zero in it. Does anyone know what that's for? Presumably it somehow controls whether the file is loaded on the client or on the server for MP play -- can anyone confirm or explain that?

Thanks -- Andarian


I believe that the client load collumn is for refferance only.  It may have been used in compiling the original code for the game as an external resource.  Now I believe it to be hard coded into the game.  I could be wrong, This is just my thoughts when i first seen the collumn.   
               
               

               
            

Legacy_GhostOfGod

  • Hero Member
  • *****
  • Posts: 1490
  • Karma: +0/-0
Script-Modify Item Base Cost?
« Reply #16 on: November 07, 2010, 07:29:08 am »


               I found this thread. Might help.

nwn.bioware.com/forums/viewtopic.html

Pretty good info in there.

EDIT: Just checked the ItemPropDef.2da. The last 3 lines are for the Material, Quality, and Additional_Property. The cost colums are all currently set to "****". So adding a cost multiplier to the last might be what ya need. Hopefully.

Good luck.
               
               

               


                     Modifié par GhostOfGod, 07 novembre 2010 - 07:50 .
                     
                  


            

Legacy_Lightfoot8

  • Hero Member
  • *****
  • Posts: 4797
  • Karma: +0/-0
Script-Modify Item Base Cost?
« Reply #17 on: November 07, 2010, 02:16:52 pm »


               Also if you need the full equation for the Item cost, It can be found in section 4.4 of the PDF link below.
http://nwn.bioware.c...Item_Format.pdf
               
               

               
            

Legacy_AndarianTD

  • Hero Member
  • *****
  • Posts: 725
  • Karma: +0/-0
Script-Modify Item Base Cost?
« Reply #18 on: November 07, 2010, 02:41:58 pm »


               Lightfoot: Thanks, I've got that. I've already modded item costing extensively in the modules, including changes in the cost of various effects and a complete rewrite of the appraise system. So I know how all of that works. What I need is very specific: a method to add and remove an increase in the base cost of items, selectively and dynamically, in-game via scripting.

I tried GOG's suggestion and it's still not working. Based on all the references, I think I must be missing something very simple and obvious. I'm going to try it again from scratch on a plain module with no other modifications and see how that goes. Since this is veering a lot into CC, I'll probably try cross-posting the question to the CC forums as well.
               
               

               
            

Legacy_AndarianTD

  • Hero Member
  • *****
  • Posts: 725
  • Karma: +0/-0
Script-Modify Item Base Cost?
« Reply #19 on: November 07, 2010, 03:39:52 pm »


               OK, I tried this on a plain vanilla mod with no other cc and it works like a charm. The 2da changes needed were to itempropdef, iprp_additional, and iprp_addcost. The item property shows up on the item, whether added in toolset or via script, and increases the cost of the item as expected and desired. My current module is merging haks from both CEP 2.2 and Project Q, so it's possible that I just missed something that's in one of them that's interfering with this (although I'm surprised by that, since was putting these in my top hak). In any event the issue seems to be on my end at this point, so I'm sure I'll eventually figure out where I went wrong. Thanks again to everyone for their help!
               
               

               


                     Modifié par AndarianTD, 07 novembre 2010 - 03:40 .
                     
                  


            

Legacy_AndarianTD

  • Hero Member
  • *****
  • Posts: 725
  • Karma: +0/-0
Script-Modify Item Base Cost?
« Reply #20 on: November 07, 2010, 05:08:34 pm »


               For anyone interested, I finally tracked this down. The list of available item properties in the game is controlled overall by itemprops.2da, and I'd forgotten that I'd put a modified version of it in my module-specific hak in 2006. That was mainly to make more item properties available to offhand equippable rods and wands when I implemented that feature back in Sanctum v2.0. That modification was based on the CEP 2.0 version of the 2da available at the time and missing valid entries for anything added to NWN or CEP since then, including the new 1.69 properties. I merged my edits with the current CEP version of itemprops.2da and now it's working fine. '<img'>

Thanks again for all the help! - Andarian
               
               

               


                     Modifié par AndarianTD, 07 novembre 2010 - 05:46 .