Overview

Reward Center is the Benefits window in the game (opened by default with the F3 key). The window has up to 7 tabs, and each tab has its own XML configuration file:

  • Check-in (DailyCheckIn): one line for each day of the month, weekly rewards (after day 7, 14, 21, 28) and a monthly reward.
  • Today's top-up (RechargeDaily): milestones of Credits topped up during the day.
  • Total top-up (RechargeTotal): milestones of Credits topped up since the account was created.
  • VIP: each VIP level can be claimed once per account.
  • Ranking: rewards for top races in Level, Reset, Wealth (total top-up) and Guild.
  • GiftCode: players type a shared gift code to receive a gift.

The "Level milestones" tab has not been made; this button is always hidden.

All rewards (items, Exp, levels, bonus points, Gens contribution points) are sent to the Gremory Case of the receiving character (EVENT source, expiry taken from Data\GremoryCase.xml). The Gremory Case must still have enough free room for each item to be created, otherwise the claim is refused.

Requirements

  • It is not tied to any key in Plugin.ini [Plugin]: the source code has no Feature() check for Reward Center, so no separate Plugin needs to be purchased. The system is switched on/off with Enable in Data\Plugin\RewardCenter\config.ini.
  • The client needs a recent Main.dll and the interface file Data\Interface\GFx\RewardCenter.ozg. The banner image can be a file in Data\Interface\GFx or a web address.
  • The top-up / VIP / ranking / GiftCode tabs use tables in the game database, created automatically by GameServer at startup: chr_daily_reward (check-in, per character), acc_recharge_log (log of real top-ups, written by the website on every successful top-up), acc_recharge_reward (claimed top-up / VIP milestones, per account), rank_race_result and rank_race_done (top race results), gift_code_log (used gift codes). If the tables are not ready, the corresponding tabs are hidden.
  • The top-up tabs take their data from acc_recharge_log: only Credits actually topped up through the website are counted (automatically paid payment orders, bank transfers approved by an admin). Credits spent in the game, transfers between accounts and vote rewards are NOT counted. The top-up time is written by SQL Server (GETDATE), so SQL Server and GameServer should use the same clock.

Configuration files

File (in Data\Plugin\RewardCenter\)Purpose
config.iniTurns the window on/off, hotkey, turns each tab on/off, banner of each tab
DailyCheckIn.xmlCheck-in tab. Gifts come from the DailyRewards\ folder
RechargeDaily.xmlToday's top-up milestones. Gifts from RechargeRewards\
RechargeTotal.xmlTotal top-up milestones. Gifts from RechargeRewards\
VipReward.xmlRewards by VIP level. Gifts from VipRewards\
RankingLevel.xml, RankingReset.xml, RankingWealth.xml, RankingGuild.xmlRanking rewards (one file per type). Gifts from RankingRewards\
GiftCode.xmlGiftCode tab. Gifts from GiftCodeRewards\
DailyRewards\, RechargeRewards\, VipRewards\, RankingRewards\, GiftCodeRewards\Gift bag files (FileName), all in the same format, see the section "Gift bag file format"

The text displayed in the window comes from Data\Lang group 49 "Reward Center" (see the Lang section below). In the XML files, do not write comments directly inside a tag.

config.ini

KeyValueDefaultMeaning
[RewardCenter] Enable0 / 10 (when the key is missing; the sample file sets 1)1 = window on. 0 = the hotkey does nothing, the window does not open. The database must also be ready.
[RewardCenter] HotkeyF1 ... F12F3Key that opens / closes the window. Any other value = no hotkey.
[Tabs] DailyCheckIn0 / 11Show the Check-in tab (a tab with no gift lines hides itself).
[Tabs] RechargeDaily0 / 11Show the Today's top-up tab (needs at least 1 milestone in the XML).
[Tabs] RechargeTotal0 / 11Show the Total top-up tab.
[Tabs] Vip0 / 11Show the VIP tab (also needs Enable="1" in VipReward.xml).
[Tabs] Ranking0 / 11Show the Ranking tab (needs at least 1 ranking type with a valid race).
[Tabs] GiftCode0 / 11Show the GiftCode tab (also needs Enable="1" in GiftCode.xml and at least 1 valid code).
[Banner_<Tab>] Imageweb address http:// / https:// or a file in Data\Interface\GFxemptyBanner image of the tab, stretched into an 887 x 71 frame. Formats PNG, JPG, BMP, GIF (animated GIF up to 60 frames), WEBP (only when Windows has a WebP codec). Each client downloads it once per play session; if you change the image on the web everyone sees the new image, with no client update needed. At most 250 characters.
[Banner_<Tab>] Linkweb addressemptyWeb page opened when the banner is clicked. Empty = clicking does nothing. At most 250 characters.

Tab names in [Banner_...]: DailyCheckIn, RechargeDaily, RechargeTotal, Level, Vip, Ranking, GiftCode.

[RewardCenter]
Enable = 1
Hotkey = F3

[Tabs]
DailyCheckIn = 1
RechargeDaily = 1
RechargeTotal = 1
Vip = 1
Ranking = 1
GiftCode = 1

[Banner_DailyCheckIn]
Image = https://example.com/banner.gif
Link = 
When configuring banners, replace the sample image address with your own image.

Tab time (StartDate / EndDate / ClaimDays)

The files DailyCheckIn.xml, RechargeDaily.xml, RechargeTotal.xml, VipReward.xml share 3 attributes on the root tag:

AttributeValueDefaultMeaning
StartDateYYYY-MM-DD HH:MM (server time)unlimited0000-00-00 00:00 or empty = unlimited. Before StartDate the lines show "Starts ..." and cannot be claimed yet.
EndDateYYYY-MM-DD HH:MMunlimitedAfter EndDate + ClaimDays, unclaimed gifts show "Ended". Must be after StartDate, otherwise the time is ignored and an error is written to the log.
ClaimDaysinteger >= 00Number of days after EndDate during which gifts can still be claimed.

The time only locks claiming gifts. A tab is never hidden because of the time; it is only hidden when turned off in config.ini [Tabs] / Enable="0". The window shows the line "Event time: start - end" under the list when a time is declared.

DailyCheckIn.xml (check-in)

Counted per character (table chr_daily_reward), starting over each month. The window shows one line for each day of the current month (28 - 31 lines), one weekly reward line after day 7, 14, 21, 28 and one monthly reward line at the end. Each day, only today's line can be claimed, once.

Root tag <DailyCheckIn>

AttributeValueDefaultMeaning
StartDate, EndDate, ClaimDayssee the section "Tab time"-Tab time.
ActiveMonths12 numbers separated by ; (month 1 ... 12), each 0 / 1not declared = no month enabled1 = check-in is possible in that month; 0 = the lines are locked ("Not active this month").
ResetHour0 - 230Hour (server time) at which the new day starts. 0 = midnight. The month also changes at this hour.
OnlineMinutesnumber of minutes >= 00Number of minutes the character must be online in this login before it can claim. 0 = claim immediately.
MinCharacterLevel>= 00Minimum total level (level + master + majestic). 0 = not required.
MinVipLevelinteger, -1 = no VIP needed-1Minimum VIP level (still valid) of the account.
AllowMissed0 / 100 = a day that has passed without claiming is lost ("Missed"). 1 = it can still be claimed late within the same month.
OpenWindowOnGameJoin0 / 111 = when entering the game with a claimable gift, the window opens automatically.

Tags <Day>, <Week>, <MonthlyBonus>

<DailyReward><Day Number="..."/> (days 1 - 31; a day that is not declared has no line; days 29 - 31 only appear in months that have that day), <WeeklyBonus><Week Number="..."/> (weeks 1 - 4: week 1 = days 1 - 7, week 2 = 8 - 14, week 3 = 15 - 21, week 4 = 22 - 28; claimable once all days of that week have been claimed) and <MonthlyBonus/> (claimable once every declared weekly reward has been claimed). These three tag types share the reward attribute set in the section "Reward attributes"; Number exists only on Day / Week.

<DailyCheckIn StartDate="0000-00-00 00:00" EndDate="0000-00-00 00:00" ClaimDays="0" ActiveMonths="1;1;1;1;1;1;1;1;1;1;1;1" ResetHour="0" OnlineMinutes="0" MinCharacterLevel="0" MinVipLevel="-1" AllowMissed="0" OpenWindowOnGameJoin="1">
	<DailyReward>
		<Day Number="1" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_DailyRewards_Day_1.xml" />
		...
	</DailyReward>
	<WeeklyBonus>
		<Week Number="1" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_DailyRewards_Week_1.xml" />
	</WeeklyBonus>
	<MonthlyBonus Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_DailyRewards_Month.xml" />
</DailyCheckIn>

Reward attributes (shared by all tabs)

Every reward tag (Day, Week, MonthlyBonus, Milestone, Vip, Rank, Code) uses the following attributes:

AttributeValueDefaultMeaning
Expinteger; 0 or -1 = none0Experience added.
LevelUpnumber of levels >= 00Number of levels the character gains (stops at the maximum level).
LevelUpPoints>= 00Bonus (stat) points added.
GensContributions>= 00Gens contribution points (only when the character belongs to a Gens family).
FileNamegift bag file nameemptyA file in the tab's gift bag folder (see the table "Configuration files"). Empty = no items. The window shows the first 4 items for the character's class in the slots; the "+" slot lists the rest and the Exp / level / points / Gens rewards on mouse hover.

Gift bag file format

Gift bag files use exactly the item bag format of Data\ItemBags. This way each character only receives the part of the items that its class / level / reset is allowed to receive. Abridged example (file RankingRewards\Event_RankLevel_1_1.xml):

<ItemBag>
<BagConfig Name="Event_RankLevel_1_1" ItemRate="10000" SetItemRate="0" SetItemCount="1" ... BagUseRate="10000" />
<SummonBook Enable="0" DropRate="0" ItemCat="0" ItemIndex="0" />
<AddCoin Enable="0" CoinType="0" CoinValue="0" PlayerMinLevel="1" PlayerMaxLevel="MAX" PlayerMinReset="0" PlayerMaxReset="MAX" />
<Ruud GainRate="0" MinValue="1" MaxValue="10" PlayerMinLevel="1" PlayerMaxLevel="MAX" PlayerMinReset="0" PlayerMaxReset="MAX" />
<DropSection UseMode="-1" DisplayName="Section 1">
	<DropAllow DW="1" DK="1" ELF="1" MG="1" DL="1" SU="1" RF="1" GL="1" RW="1" SLA="1" GC="1" LW="1" LM="1" IK="1" AC="1" CR="1" PlayerMinLevel="1" PlayerMaxLevel="MAX" PlayerMinReset="0" PlayerMaxReset="MAX" MapNumber="-1">
		<Drop Rate="10000" Type="1" Count="1">
			<Item Cat="14" Index="13" ItemMinLevel="0" ItemMaxLevel="0" Durability="30" Skill="0" Luck="0" Option="0" Exc="-1" SetItem="0" SocketCount="0" ElementalItem="0" />
		</Drop>
	</DropAllow>
</DropSection>
</ItemBag>
Tag / attributeMeaning
DropAllow DW DK ELF MG DL SU RF GL RW SLA GC LW LM IK AC CR1 = that character class receives this part, 0 = does not.
PlayerMinLevel / PlayerMaxLevel / PlayerMinReset / PlayerMaxResetLevel and reset limits (MAX = unlimited).
MapNumber-1 = any map.
Drop Rate Type CountRate is n/10000. Type 1 = give every item in the Drop; Type 0 = randomly choose Count items.
Item Cat Index ItemMinLevel ItemMaxLevel Durability Skill Luck Option Exc SetItem SocketCount ElementalItemThe item that is created.

The remaining tags (BagConfig, SummonBook, AddCoin, Ruud) follow the gift bag format in Data\ItemBags exactly.

RechargeDaily.xml and RechargeTotal.xml (top-up milestones)

Counted per account: each milestone can be claimed once per account (for RechargeDaily, once per day; table acc_recharge_reward), and the gifts are sent to the Gremory Case of the character that clicks claim. The list is re-read from the database each time the tab is opened / clicked.

Tag / attributeValueDefaultMeaning
<RechargeDaily> ResetHour0 - 230Hour at which a new "top-up day" starts (server time). Only on RechargeDaily.
root tag StartDate / EndDate / ClaimDays--See the section "Tab time".
<Milestone> Creditsnumber > 00Amount of Credits topped up to reach the milestone. Lines are shown from the smallest milestone, up to 64 milestones.
<Milestone> reward attributes--See the section "Reward attributes". Gift bags are in RechargeRewards\.
<RechargeDaily StartDate="0000-00-00 00:00" EndDate="0000-00-00 00:00" ClaimDays="0" ResetHour="0">
	<Milestone Credits="1000" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_RechargeDaily_1.xml" />
	<Milestone Credits="5000" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_RechargeDaily_2.xml" />
</RechargeDaily>

VipReward.xml (VIP rewards)

The lines of the tab are the VIP levels in Data\VIPSystem.xml (the VIP name comes from NameLangID). Each level can be claimed only once per account (table acc_recharge_reward, type 2). An account can claim every level from 1 up to its current VIP level (VIP still valid): going from VIP 0 straight to VIP 5 claims all of VIP 1 - 5. A level that has been claimed cannot be claimed again, even if the VIP expires and is bought again; only a higher VIP level gives a new gift.

Tag / attributeValueDefaultMeaning
<VipReward> Enable0 / 110 = hide the tab.
root tag StartDate / EndDate / ClaimDays--See the section "Tab time".
<Vip> Level1 - 640VIP level (Vip Type in VIPSystem.xml). A VIP level without a <Vip> tag shows "No reward set".
<Vip> reward attributes--Gift bags are in VipRewards\.
<VipReward StartDate="0000-00-00 00:00" EndDate="0000-00-00 00:00" ClaimDays="0" Enable="1">
	<Vip Level="1" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_Vip_1.xml" />
</VipReward>

RankingLevel / RankingReset / RankingWealth / RankingGuild.xml (ranking rewards)

Each file corresponds to one ranking type and shows a button on the banner of the Ranking tab. One file contains multiple races (<Race>). Only characters in the result list receive the reward; other lines only show the reward and the race status. The list is re-read from the database each time the tab is opened / clicked. Race results are stored under the key <Type>_<Id> (for example Level_1).

  • Level: total level = level + master + majestic.
  • Reset: number of resets.
  • Wealth: Credits actually topped up between StartDate and EndDate (table acc_recharge_log); counted per account, any one character of the account receives it once.
  • Guild: guild score gld_main.Score; every member of a guild in the top at EndDate receives the reward of that rank.

Root tag and Race tag

Tag / attributeValueDefaultMeaning
root tag Enable0 / 10 (when the attribute is missing; the sample file sets 1)0 = hide the button and completely disable this ranking type (no recording, no finalizing, no rewards).
Race Idnumber > 0, unique in the file0 (invalid)Race code. Results are stored by Id: a new race must use a NEW Id, never reuse an old Id (the old results would be counted).
Race Nametextthe key Type_IdName shown on the lines.
Race ModeFirst / PeriodPeriodFirst = the race ends as soon as the FIRST character reaches the milestone, that character is rank 1, and GameServer finalizes the top immediately; the following ranks are ordered by current value. Only usable for Level and Reset. Period = GameServer finalizes the top exactly at EndDate (checked every second) and the winners receive gifts.
Race Level (RankingLevel) / Race Reset (RankingReset)number > 00Milestone of Mode First (for example Level="400", Reset="100"). Must be > 0 when Mode is First. Checked when a character levels up / resets or enters the game; all sub servers share one result.
Race StartDate / EndDateYYYY-MM-DD HH:MMunlimitedMode Period must have a real EndDate (when the top is finalized); Mode First may have none. EndDate must be after StartDate, otherwise the race is ignored and an error is written to the log.
Race ClaimDays>= 07Read from the file (default 7 days after EndDate). [TO VERIFY: this value is loaded into the configuration but nothing in RewardCenter.cpp appears to use it to hide the race; the note in the XML file says winners can claim without a time limit]
Rank TopMin / TopMaxinteger >= 1TopMin 1; TopMax = TopMinRange of ranks that receive this reward (TopMin="4" TopMax="10" = ranks 4 - 10). The largest TopMax = the number of winners, at most 1000.
Rank reward attributes--See the section "Reward attributes". Gift bags are in RankingRewards\.

Which race is displayed: for each ranking type, the window shows the race that STARTED LATEST up to now (the largest StartDate not after the present; several races with the same StartDate are shown together). When a race has ended and there is no new one yet, the finalized top list is still shown. Before any race has started, the nearest upcoming race is shown. To organize a new round: add a new <Race> with a new Id and a later StartDate.

<RankingLevel Enable="1">
	<Race Id="1" Name="First to level 400" Mode="First" Level="400" StartDate="2026-01-01 00:00" EndDate="2026-11-30 23:59">
		<Rank TopMin="1" TopMax="1" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_RankLevel_1_1.xml" />
		<Rank TopMin="2" TopMax="3" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_RankLevel_1_2.xml" />
	</Race>
	<Race Id="2" Name="Level race December" Mode="Period" StartDate="2026-12-01 00:00" EndDate="2026-12-31 23:59">
		<Rank TopMin="1" TopMax="1" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_RankLevel_2_1.xml" />
	</Race>
</RankingLevel>
For RankingWealth.xml and RankingGuild.xml only Mode="Period" can be used (Mode First is ignored and an error is written to the log).

GiftCode.xml

Each <Code> tag is one line of the tab. The player types the code into the line's box and clicks Claim; the gift goes to that character's Gremory Case. One code is shared by everyone (give the same code to all players on the web / fanpage). The code is looked up by its text, so typing the correct code into any box gives the gift of that code. A line is only shown between StartDate - EndDate and when the GameServer is in ServerCode. Each claim is recorded in the table gift_code_log (GiftId, Code, CharacterId, AccountId, ServerCode, UsedAt).

Tag / attributeValueDefaultMeaning
<GiftCode> Enable0 / 110 = hide the tab.
Idnumber > 0, one Id per code0 (invalid)The table records who has used it by Id: if you only change the text of the code but keep the Id, people who already used it cannot use it again. A NEW event = a NEW Id. If an Id or Code is duplicated, the tag is ignored.
Nametextempty (shows the tab name)Name of the gift shown above the code input box.
Code1 - 32 characters: letters A-Z a-z, digits, -, _empty (invalid)The code the player types. Case-insensitive. Two tags must not have the same Code.
Type0 / 111 = each character can use it once. 0 = only 1 character on the whole server (whoever enters it first), after which the line shows "Used up".
StartDate / EndDateYYYY-MM-DD HH:MMunlimitedOutside this range the line is hidden and typing the code reports that it has not started / has expired.
LevelMin / LevelMaxinteger; LevelMax -1 = unlimited0 / -1The character's total level (normal + master + majestic).
ResetMin / ResetMaxinteger; ResetMax -1 = unlimited0 / -1The character's reset count.
ServerCode-1 or a list separated by , (for example 0,1,2)-1GameServer codes (ServerCode in GameServer.conf) on which the code works. -1 = every server.
reward attributes--See the section "Reward attributes". Gift bags are in GiftCodeRewards\. A tag without any reward is ignored and an error is written to the log.
<GiftCode Enable="1">
	<Code Id="1" Name="Happy New Year 2027" Code="NEWYEAR2027" Type="0" StartDate="2026-11-24 00:00" EndDate="2026-12-31 23:59" LevelMin="0" LevelMax="-1" ResetMin="0" ResetMax="-1" ServerCode="-1" Exp="-1" LevelUp="0" LevelUpPoints="0" GensContributions="0" FileName="Event_GiftCode_2.xml" />
</GiftCode>

Messages (Lang)

The text in the window and the messages come from Data\Lang (the language files), group Type="49" named "Reward Center", with these main ID groups:

  • IDs 1 - 7: window title, tab names, Prev / Next buttons. IDs 10 - 39: Check-in tab (for example ID 20 "[Check-in] Day %d reward has been given to the Gremory Case.", ID 21 "Gremory Case is full. %d free slot(s) needed.").
  • IDs 40 - 48: Top-up tab. IDs 50 - 54, 68: VIP tab. IDs 55 - 67, 69 - 75: Ranking tab. ID 76: the line "Event time: %s - %s".
  • IDs 77 - 90: GiftCode tab (for example ID 81 "Wrong gift code.", ID 86 "You have already used this gift code.", ID 88 "[Gift Code] The %s reward has been given to the Gremory Case.").

VIP level names come from VIPSystem (NameLangID).

Reloading the configuration

Click the Reload plugin button on the GameServer panel: GameServer reloads config.ini and the Reward Center XML files and then re-sends the configuration to players who are online. Players do not need to re-enter the game.

The note at the top of the config.ini file mentions "Reload config", but in the source code the reload of Reward Center is part of the Reload plugin function. [TO VERIFY: confirm whether the command .reload config reloads Reward Center; this document only asserts the Reload plugin button]