CABAL EP8 Website & Web API — Beginner-Friendly WIP

Newbie Spellweaver
Joined
Jul 9, 2026
Messages
6
Reaction score
7

Installation Guide​

​

This guide is written for the public sanitized release and it will be updated as development continues. It assumes you already have a working Cabal EP8 server environment and SQL Server. It covers the entire website + Web API + Shop Vendor API included in the release, including the parts that were not covered by the original WIP post.

​

1788459937320 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums

1788460212109 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums

1788460263709 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums

1788460309200 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums

1788460470477 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums


Replaces admin/_account.php.

This hotfix addresses an issue where NPC shop item lists could fail validation when items were added/deleted and the browser-side item indexes became sparse.
The submitted shop item collection is now normalized before validation/API serialization, while the actual SlotID values remain unchanged.

File to replace:

C:\xampp\htdocs\cabal\admin\_account.php

No API or SQL changes are required for this hotfix.


1. What this release is​

This release is a (WIP) complete web/account-management layer for a Cabal Episode 8 private server environment represented by the current working project snapshot. It was built around the Fallen Cabal EP8 server files and Client, together with the cabal_ep8_repack.tar + CLEAN EP8 Database Backups [Toast's] from this post, and a Client patch which I no longer remember where I found. This release is not the Cabal game server itself, a game client, or a SQL database distribution.

The release gives you a Windows-hosted website and two Linux API services which sit between the website and your SQL Server. The browser never connects directly to SQL Server.

The two APIs are separate on purpose. The normal account website uses port 38250. The Shop Vendors editor uses port 38251. Installing only the first API will therefore not provide a fully functioning Shop Vendors system.

2. What the website can actually do​

The following is the functionality represented by the current working website/API release. This is the functionality this tutorial is intended to install and verify.

Public player/account side​

Account registration​

Players can create Cabal accounts through the website. The registration request is handled by the Main Web API and written to the ACCOUNT database.

Login​

Players can authenticate through the website and enter the account portal. The website does not connect directly to SQL Server; the request goes through the Main Web API.

Account information​

The account portal can display account information exposed by the current API/database implementation.

Character list and character information​

The website can retrieve the characters belonging to the logged-in account and display their information.

Character stat allocation​

The character interface exposes the supported stat-allocation operation. When the server/database conditions permit it, the player can allocate STR/DEX/INT through the web interface rather than editing the database manually.

Top 5 ranking​

The public website can request and display the ranking information implemented by the Main Web API.

Cash balance​

The account portal can read the account cash balance exposed by the API.

Premium Service​

The current implementation contains Premium status information and the supported Premium operations, including purchase and end operations where the underlying database/server configuration supports them. Ending Premium is handled by the API according to the current implementation.

Welcome bonus​

The website includes the implemented account welcome-bonus workflow and its status checks.

Client download​

The public website contains a client-download button/area that you can point to your own Cabal client hosting URL.

Administrator / GM side​

The release contains a protected Admin Control Center. The current API and website expose the following administrative operations.

Server rate management​

The Admin Control Center can read and modify the exposed server rate configuration. The current interface includes:

EXP
SKILL EXP
CRAFT EXP
DROP RATE
ALZ BOMB
ALZ AMOUNT
It also supports the exposed All_M and PC_M rate sets and provides rollback functionality through the API.

Premium Service configuration​

The Main Admin can read, modify, and roll back the Premium Service configuration values exposed by the API.

Account management​

The administrator can retrieve the account list and associated character information through the Admin Control Center.

Cash management​

The administrator can add or deduct account cash through the administrative interface.

Account access control​

The administrator can use the supported account-access controls to enable/block account access. The exact database-side result depends on the schema used by the Cabal environment.

GM management​

The Admin Control Center exposes the implemented character-GM management operations, including setting/checking character GM status and the related Nation 3 authorization functionality implemented by the API.

Item delivery / mailbox​

The Admin/GM interface includes the Cabal mailbox item-delivery function. The administrator can select an item from the supplied item catalog and send it to a character; the current implementation also supports the account-wide delivery operation exposed by the API for easy gift distribution.

Item catalog​

The website package contains an item catalog used by the item-delivery interface. This catalog is a web-interface lookup resource; it does not replace the server's own authoritative item definitions.

Shop Vendors​

The Admin Control Center contains a dedicated Shop Vendors editor backed by the separate Shop Vendor API on TCP port 38251.

The current Shop system can:

Read the configured NPC shops
Display vendors/worlds
Read individual shop entries
Resolve ItemKind definitions
Resolve Item.scp statistics
Display OptionPool context
Resolve the shop-entry ItemOpt from NPCShop.scp
Add/edit shop items
Save vendor configurations
Verify saved vendor data
Rollback shop configuration
The Shop editor deliberately keeps the shop-specific ItemOpt value separate from the base Item.scp item statistics. This is important for correct EP8 shop editing.

3. What is included in the release​

The public release contains the current working website, API clients, both server-side Python APIs, both systemd service definitions, and the Shop API's required data files.

website/
.htaccess
config.php
index.php
register.php
api_client.php
readability.css
text-size.css
admin_account.php
admin_cash.php
shop_test.php
dev_notes.php
admin/
_account.php
item_catalog.csv
shop_vendor_names.json

centos/
server_api/
proto_cabal_webapi.py
proto_cabal_shopapi.py

service_definitions/
proto-cabal-webapi.service
ProtoCabalShopAPI.service

api_data/
Item.scp
NPCShop.scp
OptionPool.scp
shop_vendor_names.json

The release is sanitized. It does not contain the original project's live API token, SQL password, private LAN address, database backups, service status snapshots, or other machine-specific credentials.

4. Prerequisites — read this before downloading/extracting anything​

You need the following before beginning the installation.

Required server environment​

You should already have:

[ ] A working Cabal EP8 server
[ ] A working SQL Server instance
[ ] The ACCOUNT database
[ ] The Server01 database
[ ] A Windows computer for Apache/PHP
[ ] A Linux server or VM for the Python APIs
[ ] Network connectivity between Windows and Linux
[ ] A Cabal game client (if you intend to use the client-download feature and check website Mail functionality etc)
This release does not create a Cabal server, install your Cabal database, or provide your game client.

Recommended operating-system/environment versions​

This project was developed around a legacy environment. For the first installation, reproduce the environment as closely as possible instead of attempting to modernize it at the same time.

Windows​

Recommended:

Windows

The legacy PHP version supplied with that XAMPP generation
Apache

The intended website root is:

C:\xampp\htdocs\cabal

​

Linux​

Recommended:


Python 2-compatible runtime
SQL Server
systemd

The supplied API scripts use Python 2-compatible modules such as BaseHTTPServer, so do not assume that a modern Python 3-only installation can execute them unchanged. Porting them to a modern Python environment is a separate development task.

Network requirements​

The Windows website must be able to reach the Linux machine on:

TCP 38250 Main Web API
TCP 38251 Shop Vendor API

The Linux APIs must be able to reach SQL Server locally through the configured sqlcmd path.

SQL requirements​

The APIs need a SQL login that can perform the queries/procedures required by this release. Use a dedicated SQL login for the APIs whenever possible.

Do not publish or distribute your sa password.

Information you must have ready​

Before starting, have these values available:

YOUR_WINDOWS_IP
YOUR_API_SERVER_IP
YOUR_API_TOKEN
YOUR_SQL_API_USER
YOUR_SQL_API_PASSWORD
YOUR_CLIENT_DOWNLOAD_URL

You will discover/generate most of these during the tutorial.

Basic knowledge expected​

This is intentionally beginner-friendly, but you should know the basic meaning of:

IP address
port
LAN
firewall
SQL login
password
Apache
PHP
Linux terminal
systemd

You do not need to be a professional PHP or Linux developer.

5. Installation order​

Follow the tutorial in this order:

1. Prepare SQL Server
↓
2. Install/check Linux Python environment
↓
3. Install Main Web API
↓
4. Install Shop Vendor API
↓
5. Start both systemd services
↓
6. Open/configure API firewall ports
↓
7. Install XAMPP/Apache/PHP
↓
8. Install website
↓
9. Configure website API addresses/token
↓
10. Test Windows → Linux connectivity
↓
11. Test registration/login
↓
12. Test player functions
↓
13. Test Admin Control Center
↓
14. Test Shop Vendors
↓
15. Configure client download URL

Do not troubleshoot multiple layers at once. If SQL is broken, fix SQL first. If the API service is stopped, fix the API before changing PHP.

5. Step 1 — Install XAMPP on Windows​

Install XAMPP 1.7.1.

The website will be installed under:

C:\xampp\htdocs\cabal

Start Apache from the XAMPP Control Panel.

6. Step 2 — Check PHP​

Create:

C:\xampp\htdocs\phpinfo.php

Put this inside:

<?php
phpinfo();
?>

Open:


Check the PHP version.

After checking it, delete phpinfo.php.

7. Step 3 — Install the website​

Extract the website directory from the release so its contents are directly inside:

C:\xampp\htdocs\cabal

Correct:

C:\xampp\htdocs\cabal\index.php
C:\xampp\htdocs\cabal\config.php
C:\xampp\htdocs\cabal\api_client.php
C:\xampp\htdocs\cabal\register.php
C:\xampp\htdocs\cabal\admin\_account.php

Incorrect:

C:\xampp\htdocs\cabal\cabal\index.php

Do not nest the website package inside a second cabal folder.

8. Step 4 — Find the Windows IP​

Open Command Prompt and run:

ipconfig

Find the IPv4 address of the network adapter that other machines will use to reach this website.

Call it:

YOUR_WINDOWS_IP

Example only:

192.168.1.100

Do not copy the example into your real configuration.

9. Step 5 — Find the Linux API IP​

On the Linux machine run:

hostname -I

or:

ip addr

Choose the address that the Windows machine can reach.

Call it:

YOUR_API_SERVER_IP

If Windows and Linux are different machines, do not use 127.0.0.1 for the API host.

10. Step 6 — Install the main Web API​

Copy:

centos/server_api/proto_cabal_webapi.py

to:

/usr/local/bin/proto_cabal_webapi.py

Then:

chmod 755 /usr/local/bin/proto_cabal_webapi.py

The supplied script is Python 2-compatible.

11. Step 7 — Configure the main Web API​

Open:

nano /usr/local/bin/proto_cabal_webapi.py

At the top, configure:

BIND_IP='YOUR_API_SERVER_IP'
BIND_PORT=38250
API_TOKEN='YOUR_API_TOKEN'
SQL_USER='YOUR_SQL_API_USER'
SQL_PASSWORD='YOUR_SQL_API_PASSWORD'
SQLCMD='/opt/mssql-tools18/bin/sqlcmd'

Only replace the values. Keep the variable names.

API token​

Create a new random token for your own server.

For a Python 2 environment:

python -c "import os,base64; print(base64.urlsafe_b64encode(os.urandom(32)))"

Save that token. You will use the exact same token in the Windows website configuration and both API services.

Never reuse another server owner's token.

12. Step 8 — Configure the website​

Open:

C:\xampp\htdocs\cabal\config.php

Set:

define('API_HOST','YOUR_API_SERVER_IP');
define('API_PORT',38250);
define('API_TOKEN','YOUR_API_TOKEN');

define('SHOP_API_HOST','YOUR_API_SERVER_IP');
define('SHOP_API_PORT',38251);

The token must exactly match the token configured on Linux.

The Shop Vendor system is separate and uses TCP 38251.

13. Step 9 — Prepare SQL access​

Use a dedicated SQL login for the web API. Do not distribute your SQL Server sa password.

The supplied API expects:

YOUR_SQL_API_USER
YOUR_SQL_API_PASSWORD

The exact database permissions required depend on the schema and stored procedures in your Cabal database. Do not blindly grant sysadmin or db_owner.

14. Step 10 — Test SQL before testing the API​

First check SQL Server:

systemctl status mssql-server --no-pager -l

Then:

/opt/mssql-tools18/bin/sqlcmd \
-S localhost \
-U YOUR_SQL_API_USER \
-P 'YOUR_SQL_API_PASSWORD' \
-C \
-Q "SELECT name, state_desc FROM sys.databases ORDER BY name;"

You should see the databases required by your Cabal environment, normally including:

ACCOUNT
Server01

If this test fails, fix SQL first.

15. Step 11 — Find sqlcmd if the path is different​

Check:

ls -l /opt/mssql-tools18/bin/sqlcmd

If it is not there:

which sqlcmd

or:

find /opt /usr -type f -name sqlcmd 2>/dev/null

Use the resulting path in SQLCMD=.

16. Step 12 — Install the main API systemd service​

Copy:

centos/service_definitions/proto-cabal-webapi.service

to:

/etc/systemd/system/proto-cabal-webapi.service

The supplied service starts:

/usr/bin/python /usr/local/bin/proto_cabal_webapi.py

If your Python executable is different, change only the executable path in ExecStart.

Then run:

systemctl daemon-reload
systemctl enable proto-cabal-webapi.service
systemctl start proto-cabal-webapi.service

Check:

systemctl status proto-cabal-webapi.service --no-pager -l

You want:

active (running)

17. Step 13 — Check the main API port​

Run:

ss -lntp | grep 38250

You should see the API listening on port 38250.

If not, read the API log:

journalctl -u proto-cabal-webapi.service -n 100 --no-pager

For live logs:

journalctl -u proto-cabal-webapi.service -f

Press Ctrl+C to stop the live log.

18. Step 14 — Install the Shop Vendor API​

This is the part that is easy to miss.

The website's Shop Vendors functionality uses a second API service.

Copy:

centos/server_api/proto_cabal_shopapi.py

to:

/usr/local/bin/proto_cabal_shopapi.py

Then:

chmod 755 /usr/local/bin/proto_cabal_shopapi.py

​

19. Step 15 — Configure the Shop Vendor API​

Open:

nano /usr/local/bin/proto_cabal_shopapi.py

Set:

BIND_IP='YOUR_API_SERVER_IP'
BIND_PORT=38251
API_TOKEN='YOUR_API_TOKEN'
SQL_USER='YOUR_SQL_API_USER'
SQL_PASSWORD='YOUR_SQL_API_PASSWORD'
SQLCMD='/opt/mssql-tools18/bin/sqlcmd'

The API_TOKEN, SQL_USER, and SQL_PASSWORD must correspond to your own server.

20. Step 16 — Install the Shop API data files​

The Shop API reads these files:

/etc/cabal/Data/NPCShop.scp
/etc/cabal/Data/Item.scp
/etc/cabal/Data/OptionPool.scp

Copy the release's matching files into the corresponding locations only if those files are intended to be the baseline for your environment.

If your EP8 server already has its own working NPCShop.scp, Item.scp, and OptionPool.scp, back them up and compare them before replacing them. The Shop API is designed around those server-side data sources.

The website's item resolver uses the item definition and option-pool context, while the shop entry's ItemOpt remains the separate shop value stored in NPCShop.scp.

21. Step 17 — Install the Shop API systemd service​

Copy:

centos/service_definitions/ProtoCabalShopAPI.service

to:

/etc/systemd/system/ProtoCabalShopAPI.service

Then:

systemctl daemon-reload
systemctl enable ProtoCabalShopAPI.service
systemctl start ProtoCabalShopAPI.service

Check:

systemctl status ProtoCabalShopAPI.service --no-pager -l

You want:

active (running)

​

22. Step 18 — Check Shop API port 38251​

Run:

ss -lntp | grep 38251

The Shop API should be listening on:

38251

The main Web API and Shop API therefore use two separate ports:

38250 = account/main Web API
38251 = Shop Vendor API

​

23. Step 19 — Configure the Linux firewall​

Check:

firewall-cmd --list-ports

For a LAN installation you may need:

firewall-cmd --permanent --add-port=38250/tcp
firewall-cmd --permanent --add-port=38251/tcp
firewall-cmd --reload

For an Internet-facing installation, do not expose these API ports unnecessarily. Ideally only the trusted website host can reach them.

24. Step 20 — Test Windows to Linux connectivity​

On Windows PowerShell:

Test-NetConnection YOUR_API_SERVER_IP -Port 38250
Test-NetConnection YOUR_API_SERVER_IP -Port 38251

Both should report:

TcpTestSucceeded : True

If either test fails, check:

  • correct Linux IP
  • API service running
  • listener present
  • firewall
  • bind address
  • network route

25. Step 21 — Use the built-in service connectivity test​

The release includes:

C:\xampp\htdocs\cabal\shop_test.php

Open:


It checks connectivity to both configured services:

Account API
Shop API

This is a network connectivity test, not a complete application test.

26. Step 22 — Test the website​

Open:


From another LAN computer use:

http://YOUR_WINDOWS_IP/cabal/

The website should load before you begin testing account functionality.

27. Step 23 — Test public/account functions​

The current website/API combination includes:

Registration​

Players can create accounts.

Login​

Players can authenticate and enter the account portal.

Account information​

The portal can display account information exposed by the API.

Characters​

Characters belonging to the account can be displayed.

Stat allocation​

The character interface can use the API to add STR/DEX/INT points when supported by the database.

Top 5 ranking​

The public site can retrieve the ranking exposed by the API.

Cash​

The portal can display account cash and perform supported cash operations.

Premium​

The portal includes Premium status, purchase/end functionality, and the welcome-bonus functionality included in the current release.

28. Step 24 — Test the Admin Control Center​

Use the protected administrator interface included in the website.

The current admin layer communicates with the API for:

Server rates​

Premium Service configuration​

Account management​

Cash control​

Access control​

GM management​

Item mail​

Item catalog​


29. Step 25 — Configure the Shop Vendors system​

The Shop Vendors control is separate from the ordinary account API.

It communicates through:

SHOP_API_HOST
SHOP_API_PORT = 38251

The Shop API implements:

shop_read
shop_item_resolve
shop_save_vendor
shop_rollback

The current editor supports vendor/item reading, item definition resolution, vendor saving, and shop rollback.

Item resolution​

The resolver uses:

Item.scp
OptionPool.scp
NPCShop.scp
ItemKind and base item statistics come from the item-definition data. The shop-entry ItemOpt remains its own NPCShop.scp value.

This distinction is important when configuring shops.

30. Step 26 — Test Shop Vendors safely​

Open the Admin Control Center and enter Shop Vendors.

Read a vendor first.

Before changing anything, confirm the displayed vendor/items match your existing NPCShop.scp.

When adding an item, select the item and allow the resolver to populate the shop-specific fields.

For an item that already exists in the shop, compare the resolved values against the existing entry before saving.

Only save after you are satisfied with the changes.

31. Step 27 — Shop API rollback​

The Shop API maintains server-side backups in its configured backup directory:

/etc/cabal/Data/.admin_backups
Use the Shop Vendors rollback function only when you understand which saved shop state you are restoring.

32. Step 28 — Configure the client download link​

The main website contains a client download area.

Open:

C:\xampp\htdocs\cabal\index.php
Search for:

mega.nz
or:

Download Client
Replace the supplied download URL with your own client-hosting URL.

Do not publish somebody else's private client URL in your deployment.

33. Website IP and API IP are different​

A common setup is:

Windows website:
192.168.1.100

Linux API:
192.168.1.200
The website's API_HOST and SHOP_API_HOST point to 192.168.1.200.

Players visit:

They do not have to connect directly to the API.

34. LAN versus Internet address​

Do not confuse:

192.168.x.x
with your public Internet address.

For a public deployment, visitors normally use your domain name or public address to reach Apache. The internal API addresses remain internal wherever possible.

35. Troubleshooting — use this order​

Do not randomly modify PHP files when the underlying service is broken.

Work from the bottom upward.

SQL​

systemctl status mssql-server --no-pager -l
/opt/mssql-tools18/bin/sqlcmd \
-S localhost \
-U YOUR_SQL_API_USER \
-P 'YOUR_SQL_API_PASSWORD' \
-C \
-Q "SELECT name, state_desc FROM sys.databases;"

Main API​

systemctl status proto-cabal-webapi.service --no-pager -l
journalctl -u proto-cabal-webapi.service -n 100 --no-pager
ss -lntp | grep 38250

Shop API​

systemctl status ProtoCabalShopAPI.service --no-pager -l
journalctl -u ProtoCabalShopAPI.service -n 100 --no-pager
ss -lntp | grep 38251

Windows connectivity​

Test-NetConnection YOUR_API_SERVER_IP -Port 38250
Test-NetConnection YOUR_API_SERVER_IP -Port 38251

Apache/PHP​

Check:

C:\xampp\apache\logs\error.log
Only after these layers are healthy should you start modifying application code.

36. Common mistakes​

Wrong API IP​

Do not use 127.0.0.1 when the API is on another machine.

API token mismatch​

The website and API services must use the same token.

Wrong PHP version​

Modern PHP is not automatically compatible with this legacy application.

Only installing port 38250​

The account website uses 38250, but Shop Vendors additionally requires 38251.

Shop API not installed​

The ordinary registration/login API can work while Shop Vendors fails if the second service is missing.

Wrong website directory​

Correct:

C:\xampp\htdocs\cabal\index.php
Incorrect:

C:\xampp\htdocs\cabal\cabal\index.php

SQL failure​

Fix SQL connectivity and credentials before changing API source.

37. Public-release security rules for your own contributions to this project​

Never publish:

  • real API tokens
  • real SQL passwords
  • sa passwords
  • SSH private keys
  • database backups
  • SQL dumps
  • MDF/LDF files
  • private server credentials
  • private host-specific configuration
The supplied sanitized release deliberately uses placeholders.

Each installer must replace the placeholders with their own values.

38. Final configuration checklist​

Windows​

[ ] XAMPP installed
[ ] Apache running
[ ] Legacy PHP confirmed
[ ] Website copied to C:\xampp\htdocs\cabal
[ ] config.php edited
[ ] Windows IP identified

Linux​

[ ] Linux server available
[ ] API IP identified
[ ] Python compatibility confirmed
[ ] proto_cabal_webapi.py installed
[ ] proto_cabal_shopapi.py installed
[ ] New API token generated
[ ] Dedicated SQL login configured
[ ] SQL connectivity tested
[ ] Main API service enabled/running
[ ] Shop API service enabled/running
[ ] Port 38250 listening
[ ] Port 38251 listening

Data​

[ ] Item.scp available
[ ] OptionPool.scp available
[ ] NPCShop.scp available
[ ] Shop metadata files installed as appropriate

Network​

[ ] Windows -> Linux 38250 succeeds
[ ] Windows -> Linux 38251 succeeds

Website​

[ ] Website loads
[ ] Registration works
[ ] Login works
[ ] Account information works
[ ] Characters appear
[ ] Stat allocation works
[ ] Ranking works
[ ] Cash works
[ ] Premium functions work
[ ] Admin panel works
[ ] Rates work
[ ] Premium configuration works
[ ] Account management works
[ ] Cash management works
[ ] GM/access management works
[ ] Item mail works
[ ] Shop Vendors works
[ ] Client download URL replaced

Security​

[ ] New API token generated
[ ] Same token configured on website and both APIs
[ ] Real SQL password never published
[ ] No SA password published
[ ] No database backups published
[ ] API ports restricted where possible

39. Final notes​

This release is a web management layer around an existing Cabal EP8 environment. It does not replace the underlying game server, database, or client.

Get the original legacy environment working first. Once the complete system works, modernization can be treated as a separate project.

As the current project keeps evolving, I will post them as new comments and update this original thread,

I might be able to give limited troubleshooting based on my free time.

Please leave a like/comment if this is something you are interested in. I am still learning, so any constructive criticism is welcome.

Keep the current project credits and insert your own when redistributing or modifying the release.

Cheers and I hope someone will find this useful.

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Development Update — 03/09/2026​

-updated main download link and installation steps

Shop Vendors and Admin Control Center UI​

1788462458843 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums


1788462496633 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums



1788462550193 - CABAL EP8 Website & Web API — Beginner-Friendly WIP - RaGEZONE Forums


Today's development was focused exclusively on the Admin Control Center, with the main work being the development of a completely new Shop Vendors system.

The purpose was to move NPC shop management from manual server-file editing into a practical web-based administration interface.

Shop Vendors​


A new Shop Vendors section has been developed inside the Admin Control Center.

Administrators can now:

  • Browse NPC vendors
  • Expand a vendor to view its shop
  • View individual shop items
  • Add items
  • Edit shop-entry values
  • Delete individual items
  • Save the complete vendor
  • Verify saved data through a read-back
  • Roll back shop configuration

The interface was designed around the actual structure of the Cabal shop system rather than treating shop items as arbitrary values.

Vendor and item interface​


Vendors are displayed through an expandable interface so that the administrator is not presented with every shop and every item simultaneously.

Inside an opened vendor, items are displayed in a compact two-column layout on larger screens instead of giving every item an entire row.

Each item has its own expansion and delete control, making large shops considerably easier to manage.

The item editor itself was also cleaned up so that the administrator sees the actual shop-editing fields without being presented with unnecessary server-definition information.


Add Item and Item Resolution​


The Add Item workflow is one of the more important parts of today's development.

When an administrator selects an ItemKind, the website sends the request to the dedicated Shop API together with the selected pool.

The API then resolves the item against the server's actual data:

Item.scp
OptionPool.scp
NPCShop.scp

The three sources serve different purposes.

Item.scp provides the underlying item definition and base statistics.

OptionPool.scp provides the relevant option-pool context.

NPCShop.scp provides the actual shop-entry configuration.

The system therefore does not simply create a new item with empty or guessed shop values.


ItemOpt​


A particularly important issue addressed today was ItemOpt.

ItemOpt is an actual shop-entry field from NPCShop.scp. It is not simply an attribute that should be generated from the base Item.scp definition.

The new resolver searches the existing shop data for a matching item and uses the appropriate shop entry as a template.

During testing, for example, the resolver successfully returned:


ItemKind = 3
ItemOpt = 50
DurationIdx = 0
AlzPrice = 2000
Pool_ID = 1

This means that when an item is added, the website can populate its shop-specific information from an existing server definition rather than starting from a completely blank shop entry.

Shop-specific values​


The resolved shop template can provide values including:


ItemKind
ItemOpt
DurationIdx
AlzPrice
CashPrice
WExpPrice
DPPrice
MinLevel
MaxLevel
Reputation
MaxReputation
OnlyPremium
OnlyWin
Renew
CharacterBuyLimit
SellLimit
Marker

The administrator can then modify those values before saving the vendor.

Pool-aware resolution​


The resolver also takes the selected shop pool into account.

When a matching ItemKind exists in the selected pool, that entry is preferred as the template.

This is important because the same item can potentially appear in different shops with different shop-specific settings.

Saving and verification​


Saving is handled through the dedicated Shop API.


The API therefore does not simply assume that a successful write means that the complete vendor was stored correctly.

Rollback functionality is also included for shop configuration.

Dedicated Shop API​


The new Shop Vendors system uses a separate API service from the main account/web API.


The existing main Web API continues to handle the account and administration functions, while the new Shop API is dedicated to NPC shop management.

UI Polish​

​

The remainder of today's work focused on making the new system practical to use.

The Shop Vendors interface was kept compact, individual item editors were cleaned up, unnecessary technical output was removed from the normal editing view, and the overall layout was structured around the way administrators actually work with NPC shops.
Today's work therefore established the Shop Vendors subsystem itself, rather than merely modifying an existing shop editor.

There is still room for further refinement and additional functionality, but the foundation for web-based NPC shop administration is now in place.
 
Last edited:
Back