Modding new items for the shop.
Like everything else in the game, adding new items for the shop in Kudos 2 is relatively easy, and just requires a text editor (and maybe an art program like paintshop pro or photoshop).
For now, all of the buyable items in the game exist in a single file called 'assets.csv' inside the games Kudos 2\data\simulation folder. You can open up and edit this file just using windows notepad or any other text editor, but it's much easier using a spreadsheet program such as Excel. The file HAS to be saved in 'csv' format from a spreadsheet program, otherwise you will scramble it and the game will not run!
If you open up assets.csv you will see columns of data like this:
Each row in the spreadsheet that starts with a '#' represents something you can buy in the game. You can just add extra items by adding an extra line at the bottom (it's best to add stuff at the bottom or you will forget which is modded and which is part of the game). Eventually the game will be able to load in separate spreadsheets and it will be tidier. Modding a new buyable item just requires you to understand what the columns do, so here is a breakdown of them:
||This has to be '#' if this line is to be read in by the game. You can add extra lines as 'comments' by not including the '#'.
||This is normally blank. If it contains a word, its a special name indicating that a special 'class' of item is being created for this object. This is used for items that have support from special code like the books and dogs.
||This is the internal (hidden) name of the item. This can be used as a prerequisite by solo or social activities. So for example, if you own a chess set, the value 'chessset' is set to 1, and that unlocks the 'play chess' activity.
||This is the name of the item as shown in the shop, and shown for the details window for this item.
||Which shop this item is found in. The options are pets, general, books and music.
||The text that describes this item in the store and also it's details window.
||This is the graphic used for this item. It is normally a 128 x 128 pixel black and white DDS format graphic, but it could be a jpg or a bmp file too.
||This is the sound that is played when this item is bought. It must exist in the data/sounds folder and be an ogg or wav file.
||The fraction of the purchase price you get back when you sell this item.
||The purchase cost. This can be zero for services that are paid for daily.
||This is the script the game runs when you buy the item. It is used to do stuff like boost confidence when buying certain items, or boosting kudos when you buy fashionable clothes.
||This is run every day you own the item. Often it's used to apply effects that degrade immediately, effectively giving temporary boosts to attributes while the object is owned.
||This is run when the 'use' button is clicked on the items details window. It can be used to launch the interface for solo or social activities, with certain events pre-selected (probably one which this item has unlocked).
||Determine this items behavior. Valid values are REBUYABLE (which means you can buy the item more than once, and the item in the store never disappears, such as cat food). STEALABLE ( if burgled, this can be taken) SELLABLE (You get a sell button on this items details window), SERVICE (You get a cancel service button) and MEANSOFTRANSPORT (Similar to service, but if you don't have the upkeep cost's it's automatically sold for you).
||Token or Pages
||For non books, this must be '#'. For books, it's the number of pages.
||For books only, this shows what to do when you click the use button. Normally it's readbook, but it doesn't have to be.
The next few columns are only used for books. They are the prerequisites for understanding the current book. (each in a different column)
The Item Graphics
How are they done? They are usually dds files, which is a format you can export from many graphics programs using these tools. You can use a jpg or a bmp file instead, but they don't support transparency. The ones in the game are 128 pixels square and are black and white, but the dds format is 32 bit RGB with an alpha channel and no mip maps. The graphic file has to exist somewhere inside the Kudos 2\data\bitmaps folder or the My Documents\My Games\Kudos 2\mods\bitmaps folder.
If you add a new item to the game don't forget to post on the modding forum about it, and if you need a reliable place to host it, email me and I can do that for you.