Version: rf455 v0.1.2 (the same in v0.1.1).
What happens: potions whose timed buff raises the EXP, PT (mastery), item drop or mining rate change nothing. The
server accepts the potion and applies the buff, and the client shows the buff icon and timer. But EXP, PT, drops and
mining yield stay exactly the same as without it.
To reproduce:
- Use
ipcsb23 ("Potion that increases PT rate by 7X for 77 seconds"; effect 23F, potionitemeffect row 453). - Hit a monster and compare the weapon PT gained with what you gain without the buff. It's the same.
- The same happens with
ipcsb01/ipcsb02 (EXP), ipcsb06/ipcsb07 (drop) and ipcsb08/ipcsb09 (mining).
The log shows the buff going on:
potion buff applied {"eff_row": 453, "affect_key": 61893, "dur_sec": 77, "debuff": false}, followed by
potion used {"eff_code": "23F", ...}.
The data is fine. Effect 23F is ContEffectType 1, ContParamCode 0, ContParamIndex 35, value 7.0, 77 s, which is
the same shape as ipcsb03–05.
Cause, as far as i can tell from the binary:
applyPotionContEffect stores the affect. (*client).combatEPLocked sums live affects into rate[62] (code 0), plus[42] (code 1) and state[40] (code 2).- Only combat, regen and stealth code calls
combatEP. - Nothing on the reward path reads the affects:
awardExp uses exp × ini EXP rate + heldExpBonus;gain*Mastery and gainUnitPT use base × mastery rate × (1 + held-item PT bonus), and that bonus is written only by haveEffectsFor;dropLoot uses iniConfig + heldLootBonus;completeMine and doAutoMineLocked use no buffs at all.
- So rate indices 34 (EXP), 35 (PT), 36 (drop) and 37 (mining) from potions are never read. Held items with the same bonuses do work.
Affected items (gamedata_rf455.db; all have m_bExist = 1):
- 49 potions have no effect at all.
- EXP (rate 34), 29 items: ipcsb01, ipcsb02, ipcsb20, ipcsb21, ipcsb22, ipcsb29, ipcsb30, ipcsb31, ipcsb32, ipcsb36, ipcsb38, ipcsb41, ipcsb43, ipcsb44, ipday01, ipevn01, ipevn04, ipevn08, ipbpc05–07, ipcpc05–07, ipapc05–07, ipspa01, ipspa02.
- PT (rate 35), 10 items: ipcsb03, ipcsb04, ipcsb05, ipcsb23, ipcsb37, ipchu09, ipchh01, ipspa03–05.
- Drop (rate 36), 3 items: ipcsb06, ipcsb07, ipday02.
- Mining (rate 37), 6 items: ipcsb08, ipcsb09, ipcsb40, ipevn02, ipspa06, ipspa07.
- EXP and PT, 1 item: ipabd02.
- 10 potions only partly work: their attack bonus (rate 32) applies, and the EXP, PT, drop and mining parts don't. These are ipevn14, ipevn15, ipevn16, ipetw03, ipetw04, ipetw05, ipcri04, ipabd01, ipsry01 and ipsry02.
Expected: while the buff is active, EXP, PT, drop rate and mining yield are multiplied by the potion's value, as
they are for held items with the same bonus.