QuestReward.txt

Rewards granted while a quest is being advanced. Each row describes one reward action, gated by quest state and per-class availability. Rewards are tied to class progression milestones, not generic item or currency grants.

File Location#

Data/Quest/QuestReward.txt

Loaded once at GameServer startup. Changes require a restart.

Format#

//Number Type Index Quantity Level Option1 Option2 Option3 NewOption RequireIndex RequireState DW DK FE MG DL SU RF
0 1 200 10 0 0 0 0 0 0 1 1 1 1 0 0 1 0
end

Terminated by end.

Columns#

ColumnTypeEffect
NumberintReward slot within the quest. Informational - the server does not key behaviour on it
Type0, 1, 2, 4, 8, 16Reward kind. See Type values
IndexintIdentifier echoed back to the client in the reward packet. For Type 1 it is the stat-point reward ID, for Type 2 and 16 the class-change target, for Type 4 and 8 the visual reward index
QuantityintAmount. Used directly by Type 1 (stat points). Other types rely on fixed server logic and ignore this column
LevelintPresent for consistency with QuestObjective; unused by current reward handlers
Option1 / Option2 / Option3 / NewOptionintPresent for consistency; unused by current reward handlers
RequireIndexintQuest this reward belongs to
RequireState0-3Required quest state for the reward to fire. 0 fires on accept (before transitioning to accepted), 1 fires on turn-in (before transitioning to finished)
DW ... RF0-2Per-class gate. 0 = reward skipped for that class, 1 = base class, 2 = first class change or higher

Type Values#

Each row picks exactly one reward type - the server branches on the Type integer and runs the matching action. These are not bitmask bits; do not OR them together.

ValueMeaning
0Empty slot. Skipped
1Grant stat points. Quantity is added directly to LevelUpPoint. Not affected by PlusStatPoint in Common.dat
2First class change. Sets the character to class change 1 if they are still at change 0, rebuilds the preview charset, and sends the reward packet. Does not grant stats on its own
4Hero bonus. For Fairy Elf the server grants the Infinity Arrow skill. For any class the server awards (Level - 220) * PlusStatPoint stat points when Level > 220, otherwise zero
8Combo reward. Sends the reward packet to the client so it can show the combo-skill cut-scene. No server-side skill is added; the combo capability is enabled through the normal class-progression path
16Second class change. Sets the character to class change 2 if they are still at change 0 or 1, rebuilds the preview charset, and sends the reward packet. Does not grant stats on its own

To grant multiple reward actions for the same quest, add multiple rows with the same RequireIndex - one per reward type.

Quest rewards are restricted to these progression actions. For item or currency grants use the QuestWorld system or trigger an EventItemBag.

Reward Firing#

The server runs the reward list when the quest's CurrentState transitions:

  • From 0 (not accepted) to 1 (accepted) - rows with RequireState == 0 fire
  • From 1 (accepted) to 2 (finished) - rows with RequireState == 1 fire
  • From 3 (cancelled) to 1 (re-accepted) - rows with RequireState == 3 fire

The reward packet carries the character index, the row's Index field, and a type-specific amount (stat points granted, class-change target, or the row's Quantity).

Cross-File Dependencies#

AttributeRelated in
RequireIndexQuest.txt
First / second class change targetsDefaultClassInfo.txt
Hero bonus stat-point formulaCommon.dat PlusStatPoint
Quest XP multiplierCommon.dat AddQuestExperienceRate_AL0-3
NPC that drives reward flowMonster.xml via Quest.txt MonsterClass
Infinity Arrow skill (Type 4 for FE)Skill.txt

Common Issues#

  • Player completes quest but gets nothing - no row matches the player's class, or RequireState does not match the quest transition
  • Class change does not fire - Type 2 is ignored when the character is already past change 1; Type 16 is ignored past change 2. Verify ChangeUp before the quest runs
  • Hero bonus grants zero points - the character is at or below level 220; the formula is (Level - 220) * PlusStatPoint and clamps to zero below 221
  • Combo skill not unlocked - Type 8 only sends the reward visual; the combo skill itself is granted through the class-progression pipeline, not this row
  • Stat points not the expected amount - Type 1 uses Quantity directly and ignores PlusStatPoint; adjust Quantity to match the intended reward

Last updated April 21, 2026