If you run a Perfect World private server, two tasks come up constantly: granting Game Master rights to trusted staff and topping up Cubi-Coins so you (or your team) can buy from the Item Mall. This guide walks you through exactly how to add GM rights and Cubi-Coins to a Perfect World account using the methods that actually work in 2026, drawn from MySQL stored procedures, phpMyAdmin access, and the BATGM helper tool.
I have run a Perfect World server for a small community for years, and I have hit every error you can imagine with the call addGM and call usecash procedures. The steps below reflect what has worked reliably on PW 1.5.x and 1.6.x server builds, including the gotchas that forum threads usually skip over.
Table of Contents
What You Need Before You Start (Prerequisites)
Before you touch MySQL, make sure you have these prerequisites ready. Skipping any of them is the #1 reason commands “do nothing” on a Perfect World private server.
- phpMyAdmin or direct MySQL access to your game server’s database. Open
http://YOUR-SERVER-IP/phpmyadmin/in a browser and log in with your DB credentials. - The target Character ID of the player you want to modify (not the user ID — the in-game character ID).
- Debug mode enabled server-side. Without it, the debug console will not appear no matter what you press.
- The target character must be offline when you run the SQL, or fully relog after the query.
Perfect World is still an active MMO in 2026, with active private server communities like Evolved PW and Comeback PW. The procedure names below match the official PW server emulator database schema, so they apply whether you host on Windows, Linux, or a rented dedicated box.
How to Find Your Character ID in Perfect World
Most forum guides skip this step entirely, and it is the single biggest reason users get stuck. You need the Character ID (a numeric value stored in the users table), not the account login name.
Follow these steps to look it up:
- Open phpMyAdmin and select your game database (commonly named
db,pw, orgame). - Click the
userstable on the left sidebar. - Click the SQL tab and run the following query:
SELECT ID, name, email FROM users WHERE name = 'YourCharacterName';
- The
IDcolumn returns your Character ID. Save it somewhere — you will paste it into both procedures below.
Tip: if you only know the account login but not the character name, run SELECT * FROM users WHERE email LIKE '%player_email%'; to narrow down the row. The Character ID is what stored procedures like addGM and usecash actually expect.
How to Add GM Rights to a Perfect World Account via MySQL
This is the core procedure to grant GM privileges on a Perfect World private server. It uses the addGM stored procedure shipped with the PW server emulator database.
- Log in to phpMyAdmin and open your game database.
- Click the SQL tab in the top toolbar.
- Paste the following query, replacing
12345with the Character ID you found above:
call addGM(12345, 1);
- Click Go. A success message like “1 row affected” confirms the privileges were applied.
- Ask the player (or your own character) to fully log out and back in.
- Once ingame, press Ctrl + G to open the GM panel. If the panel appears, GM rights are active.
The second parameter (1) enables GM mode. Setting it to 0 removes GM rights — useful for the removal section later in this guide. Make sure the character is offline when you run the query, otherwise the privileges will not take effect until the next relog.
How to Add Cubi-Coins to a Perfect World Account via MySQL
Cubi-Coins are the virtual currency used in the Perfect World Item Mall. The server emulator exposes a stored procedure called usecash that handles both deposits and purchases, so we use the deposit form here.
- In phpMyAdmin, stay in your game database and open the SQL tab again.
- Run the following query, substituting your own Character ID and desired amount:
call usecash(12345, 0, 0, 12, 1000000, 0, 0);
- Click Go to execute.
- Wait roughly 10 minutes, then have the character log out and back in.
- Open the Item Mall (default hotkey O). The Cubi-Coins balance should now reflect the amount you added.
The parameter breakdown for call usecash is: (character_id, type, source, reason_code, amount, tax_rate, comment). The reason code 12 flags the transaction as a Cubi-Coins top-up rather than a purchase. If the balance still reads 0 after a relog, jump to the troubleshooting section — this is the most common Cubi-Coin pain point and it has a real fix.
Alternative Method: Using the BATGM Tool
Not everyone wants to write raw SQL. The BATGM tool is a third-party utility that exposes the same addGM and usecash procedures through a small GUI. It is popular on RaGEZONE and works well for new server admins who are not comfortable with phpMyAdmin.
- Download BATGM from a trusted source (search the Perfect World development board on RaGEZONE for the latest release).
- Place
BATGM.exein the same folder as your server’s database config files, or configure the.iniwith your DB credentials. - Launch the tool and enter the Character ID.
- Choose Add GM or Add Cubi, enter the amount, and click Execute.
BATGM is essentially a wrapper around the same MySQL procedures covered above. If it works, great — if it throws a connection error, drop back to phpMyAdmin and run the SQL directly. The forum user “Dragganta” reported that Cubi-Coins appeared empty after using BATGM, but after waiting 10 minutes and relogging, the balance showed up correctly. The same delay applies whether you use the GUI or raw SQL.
Console Commands Every GM Should Know
Once GM rights are active, you need to know how to actually open the GM tools inside the client. There are two consoles: a debug console and a GM panel.
Opening the Debug Console (Ctrl+J)
Press Ctrl + J in-game to open the debug console. If nothing appears, the client was launched without the console flag. Close the game and relaunch elementclient.exe with this exact parameter line:
elementclient.exe game:cpw console:1
On some clients the key is Shift + ~ instead of Ctrl+J. Try both if the first does nothing. Server-side, debug mode must also be enabled in your emulator config — otherwise the client hides the console regardless of launch flags.
Opening the GM Panel (Ctrl+G)
Press Ctrl + G to open the Game Master panel. From here you can spawn NPCs, teleport, kick or ban players, and trigger in-game events. The most common event IDs include 1001 (Double EXP), 1002 (Double Drop), and 1003 (PvP bonus). Run them by typing event start <ID> in the GM panel.
How to Remove GM Rights from a Perfect World Account
This is one of the most asked questions on Perfect World private server forums, and only one major guide covers it. To revoke GM rights, run the same addGM procedure with 0 as the second parameter:
call addGM(12345, 0);
The character must be offline. After the next login, pressing Ctrl+G will no longer open the GM panel. This is the cleanest way to demote a staff member without touching the password or deleting the account. If you want to wipe all traces, you can also null the gm column directly with UPDATE users SET gm = 0 WHERE ID = 12345;.
Troubleshooting Common Issues
Even when the SQL is correct, Perfect World private servers throw curveballs. Here are the issues I and other admins hit most often, and the actual fixes.
Cubi-Coins showing as 0 after adding
The most reported problem on forums. The fix is patience: wait 10 minutes after running call usecash, then have the player relog. The server caches Cubi balances and refreshes them on a short timer. Forcing a server restart also clears the cache immediately.
Ctrl+J debug console does not appear
Two things must be true: the client was launched with console:1, and the server has debug mode enabled. If either is missing, the console will not show up no matter what you press. Check your emulator’s config file for the debug flag and restart the server if you change it.
Account says “max Cubi usage reached”
Some server configs cap total Cubi-Coins spent per account. If a player has already spent their cap, additional deposits will appear to succeed but the balance will not increase. Reset the total with UPDATE users SET cubi_total = 0 WHERE ID = 12345; in phpMyAdmin.
GM commands work but character cannot move or interact
You probably granted GM rights while the character was online. Always ask the player to fully log out before you run call addGM. Their client caches permission data, and only a fresh login re-reads the new GM flag from MySQL.
“Access denied” when running the stored procedure
Your MySQL user lacks EXECUTE privileges on the game database. Log in as root and run GRANT EXECUTE ON your_game_db.* TO 'your_user'@'localhost';, then retry the procedure call.
Frequently Asked Questions
Is Perfect World still active in 2026?
Yes. Perfect World International still runs official servers, and a large private server community is active on builds like 1.5.3 and 1.6.x. Private servers like Evolved PW and Comeback PW host thousands of players.
Why are my Cubi-Coins showing 0 after adding them?
The Perfect World server caches the Cubi balance for roughly 10 minutes. Wait that long, then have the character log out and back in. Restarting the game server forces an immediate refresh.
Can I add GM rights without phpMyAdmin?
Yes. The BATGM tool exposes the same addGM and usecash procedures through a small GUI. You still need valid MySQL credentials, but you do not have to write SQL by hand.
How do I remove GM rights from a Perfect World account?
Run call addGM(character_id, 0) in phpMyAdmin while the character is offline. The next login will no longer have Ctrl+G GM panel access.
Do I need to register a separate account for GM testing?
It is strongly recommended. Create a dedicated test character in a separate account, grant it GM rights, and use it for admin actions. This keeps your main account clean and avoids accidental damage to your player progress.
Final Thoughts
Adding GM rights and Cubi-Coins to a Perfect World account is a 5-minute job once you know the right stored procedures and have your Character ID on hand. Stick with call addGM(character_id, 1) for GM privileges and call usecash(character_id, 0, 0, 12, amount, 0, 0) for Cubi-Coins, always make sure the target character is offline, and give the server 10 minutes to refresh its cache. Bookmark this page and you will never have to dig through a 2009 forum thread again.