Add and Change Medals
A medal is a small item that a player puts in a medal slot of a hero. It gives growth points to the hero or to its gear. This guide covers the medal table, the client text and icon, how a medal gets to a player, and how to check it.
Names come from the code that loads the files: ioMedalItemInfoManager.cpp on the server (ls_gamesvr\NodeInfo\) and on the client (LSClient\). Anything not checked is marked not confirmed yet.
The files
Section titled “The files”| File | Where | Holds |
|---|---|---|
sp2_medalitem_info.ini |
server ls_gamesvr\config\ and client config\ |
Every medal: stats, level limit, class limit. The client copy also holds name, icon and manual |
sp2_medal_inven_manual.ini |
client config\ |
The tooltip text of each medal ([ManualN]) |
sp2_medal_info.ini |
server and client | Level medal plan ([LevelMedal]). Which code loads it: not confirmed yet |
| the locale text table | client packs | Window text. Medal names are in sp2_medalitem_info.ini, not here |
The server file and the client file must have the same medals with the same numbers. If a medal is in only one of them, expect wrong or missing data. The exact symptom of each case: not confirmed yet.
Step 1: read the structure
Section titled “Step 1: read the structure”sp2_medalitem_info.ini has four parts:
[sell_info]mortmain_item_sell = 1000.00ftime_item_sell = 0.14f
[slot_info]max_info = 6level_over_1 = 0slot_num_1 = 1level_over_2 = 10slot_num_2 = 2
[item_info_common]max_item_info = 20000
[item_info_1]item_type = 1limit_level = 0max_class = 0[slot_info]says how many medal slots a hero has at each hero level. Here level 0 gives 1 slot, level 10 gives 2 slots, up to 6 slots (GetSlotNum).[sell_info]sets the sell-back values. The loader also readsitem_sell_devide_day(default 30).[item_info_common]max_item_infois how many[item_info_N]blocks the loader walks. The shipped files use 20000.- Each
[item_info_N]block is one medal.Nis only the position. The medal id isitem_type. A block withitem_typeof0or lower is skipped.
Step 2: add a medal
Section titled “Step 2: add a medal”-
Choose a free
item_type. Search the file for it first. The loader keeps the first block that matches (GetItemInfo), so a duplicate is ignored. -
Add a block with a number
Nthat is not used and is lower thanmax_item_info. If yourNis higher, raisemax_item_info. -
Fill in the server block:
[item_info_20001]item_type = 20001limit_level = 0sell_peso = 1000max_class = 2use_class_1 = 1use_class_2 = 2char_growth_1 = 0char_growth_2 = 3char_growth_3 = 0char_growth_4 = 0item_growth_1 = 0item_growth_2 = 0item_growth_3 = 0item_growth_4 = 0Key Meaning limit_levelHero level needed to equip it. 0means nonemax_classanduse_class_NAllowed hero numbers. max_class = 0means any herochar_growth_1tochar_growth_4Points added to the hero: attack, defense, move speed, drop damage reduction (the order comes from a comment in the file) item_growth_1toitem_growth_4Points added to the gear: weapon skill, armor skill, helmet skill, cloak skill (same comment) sell_pesoSell-back value in peso The loader reads exactly four
char_growthand fouritem_growthkeys (MAX_CHAR_GROWTH,MAX_ITEM_GROWTH). Missing keys count as0. A value of-1is used by the rank medals, so negative values are allowed. -
Add the client look to the client block with the same
item_type:name = <Medal of Test>icon = UIIconPack11#goods_medal_testmanual = 20001nameis the text in the inventory.iconisimageset#image(see step 4).manualis the number of a[ManualN]block insp2_medal_inven_manual.ini.subiconis optional.
Step 3: stat-select (custom) medals
Section titled “Step 3: stat-select (custom) medals”Medals with sub_medal_type = 2 let the player choose the stats. The server reads these keys only for this type:
sub_medal_type = 2total_point = 45enable_select_stat = 4min_stat_point = 5max_stat_point = 15For sub_medal_type = 1 (the default) the fixed char_growth and item_growth values are read. The meaning of every enable_select_stat value: not confirmed yet.
Step 4: icon and text
Section titled “Step 4: icon and text”-
The icon is
ImagesetName#ImageName. Find the imageset inxml\uiimageset.xml(2021 client). EachImagesetpoints to a.ddsfile inresource\texture\. -
To add a new picture, put the
.ddsin the texture folder and add anImageentry withX,Y,Width,Heightto the imageset. Add only your own entries and keep the rest of the file as it is. -
For the tooltip, add a block to
sp2_medal_inven_manual.ini:[Manual20001]1SpaceLine = 01Color1 = 0xFF5B37141Text1 = Gives a small attack bonus[Info] MaxManualat the top (30000 in the shipped file) must be at least your number. -
Non-Korean clients print
%1 %2in text, Korea uses%s %d. The medal names above are plain text. If you use a number placeholder in a manual line, copy the style from the lines around it.
Step 5: how a player gets the medal
Section titled “Step 5: how a player gets the medal”No shop tab that sells medals was found in the code. A medal arrives as a gift (present) of type 9 (PRESENT_MEDALITEM in ioUserPresent.h):
Value1is the medalitem_type.Value2is the time limit in hours.0means permanent (ioUserPresent.cpp).
You can use it in these places:
| Source | File |
|---|---|
Gashapon reward Type = 9 |
sp2_gashapon_present.ini, see Gacha boxes |
Super gashapon element Type = 9 |
sp2_super_gashapon_present.ini |
| Quest, monster or event reward | sp2_quest_present.ini, sp2_monster_present.ini. The exact keys per file: not confirmed yet |
| Medal slot expansion | etc items EIT_ETC_EXPAND_MEDAL_SLOT01 (type 1001386) to ...SLOT20 (1001405) |
For a normal shop sale you would need an etc item that grants the medal. Whether such an etc item exists in the shipped data: not confirmed yet.
Step 6: check it
Section titled “Step 6: check it”- Restart the game server and the client.
- Give the medal with a test gift (gashapon or a test reward).
- Open the medal inventory. Check the name, the icon and the tooltip.
- Equip it on an allowed hero. Check the growth values on the hero.
Common problems:
| Symptom | Cause |
|---|---|
| Medal missing in inventory | item_type is not in the client file, or max_item_info is too low |
| Empty icon | Wrong imageset#image name |
| Cannot equip | Hero level below limit_level, hero not in use_class_N, or no free slot ([slot_info]) |
| Wrong stats | Server and client values differ. Make them equal. Which side wins in game: not confirmed yet |
Differences between versions
Section titled “Differences between versions”| 2014 | 2019 | 2021 | |
|---|---|---|---|
Loader reads sub_medal_type, total_point, enable_select_stat |
no | yes | yes |
Client reads subicon |
no | yes | yes |
| Medal gift type 9 | yes | yes | yes |
| Client config | inside rs.iop |
inside rs.iop |
plain config\ |
The 2014 server file contains sub_medal_type lines, but the 2014 loader ignores them.
