Tutorial Server/Client Scarlet Blade

Junior Spellweaver
Joined
Jun 20, 2022
Messages
124
Reaction score
21
This tutorial is work in progress, i will add more and more things for help create your home server for Scarlet Blade.

The game now is not finish, we are working in the client, there are issues with client in game. But the client work like 70%. The biggest issue is you cant sell/buy items, enhance it.

It will be not easy to install all parts and configure it

For help please ask in this thread : https://forum.ragezone.com/f857/scarlet-blade-server-files-client-1163598/


For all this tutorial i will show my config, you can easy change it to your local config, you need only change all IP 192.168.1.14 to your IP

Prerequisites

- Windows SqlServer
- Apache/php server like Wamp

Download

Server :
Client :
Client exe SB2 (we will use SB.exe Jun 14 US) :
API :

Error

You will have many error for start all parts form the server, it will ask for DLL files, this files can be found in Microsoft Visual C++ Redistributable (version 2005-2008-2010)

Installation


Data base Account update table "tbl_WorldList" -> WorldIP and WorldIPForServer to 192.168.1.14
Data base Game update table "tbl_ZoneList" -> ZoneIP and ZoneIPForServer to 192.168.1.14


LoginServer config

<?xml version="1.0" encoding="ansi"?>
<LoginServerConfig>
<!-- 시스템 설정값 AutoStart(0:대기,1:자동시작) -->
<System
AutoRun = 1
></System>
<!-- 네트웍 설정값 -->
<Network
IP = "192.168.1.14"
Port = 10001
IPForServer = "192.168.1.14"
PortForServer = 20001
></Network>
<!-- 데이터베이스 설정값 -->
<Database
IP = "localhost"
Name = "QueensAccount"
ID = "queens_db_login"
Pwd = "queens_db_pass"
></Database>
<!-- 계정 데이터베이스 설정값 -->
<AccountDB
IP = "localhost"
Name = "QueensAccount"
ID = "queens_db_login"
Pwd = "queens_db_pass"
></AccountDB>
<!-- 접속 게임로그 서버 설정값 -->
<GameLogServer
IP = "192.168.1.14"
Port = 20007
PortForServer = 20007
></GameLogServer>
<!-- 접속 PC방 빌링 서버 설정값 -->
<PCBangServer
Enable = 0
IP = "192.168.1.14"
IP_ = "192.168.1.14"
Port = 7520
></PCBangServer>
<!-- api.test.aeriagames.com -->
<WebLogin
WebLogin = 1
Host = "sb"
Protocol = "http"
SecretKey = "41447a2d3b3f3e75bee90e645ae8fdfe41f84a721e99a80f36"
></WebLogin>
<!-- 클라이언트 버전 설정값 -->
<Client
Version = 31
></Client>
</LoginServerConfig>

The Bat file exemple for connect client to server :
SB2.exe /connetip:192.168.1.14 /connetport:10001 /clientauthcode:5529056734e4f67d82d788e01773fa1273488ab4 /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1
 
Last edited:
Thanks for your contribution, I tried a lot of settings, postman can also debug tokens, but every time I log in it it will show disconnected
INFO[0x00000898][CLoginApplication::OnRecvClient]Undefined Protocol Client MSG!!! : (0, 40) INFO[0x00001d1c][CLoginApplication::OnRecvClient]Undefined Protocol Client MSG!!! : (0, 40)
 
Thanks for your contribution, I tried a lot of settings, postman can also debug tokens, but every time I log in it it will show disconnected
INFO[0x00000898][CLoginApplication::OnRecvClient]Undefined Protocol Client MSG!!! : (0, 40) INFO[0x00001d1c][CLoginApplication::OnRecvClient]Undefined Protocol Client MSG!!! : (0, 40)

You are using the wrong version of the client. Take the correct version from the description.
 
I use the client in the link, and the login uses SB2, 14US. Is this the problem with the client?
 
I have solved my problem and I will continue to develop this game



sb2.exe /connetip:192.168.1.78 /connetport:10001 /clientauthcode:0109b8225cada1dee963ea5e5b6b4cab3aa478fd /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1
Login set up
<WebLogin WebLogin = 1 Host = "192.168.1.78" Protocol = "http" SecretKey = "41447a2d3b3f3e75bee90e645ae8fdfe41f84a721e99a80f36"
192.168.1.78,Is my local IP,
 
Other version for Bat File auto connection :

1st need modify authorize.php to :

<?php

session_start();

if(!isset($_SESSION["loggedin"]) || $_SESSION["loggedin"] !== true){
header("location: login.php");
exit;
}

// include our OAuth2 Server object
require_once __DIR__.'/server.php';

$request = OAuth2\Request::createFromGlobals();
$response = new OAuth2\Response();
$userid = $_SESSION["username"];

// validate the authorize request
if (!$server->validateAuthorizeRequest($request, $response)) {
$response->send();
die;
}
// display an authorization form


// print the authorization code if the user has authorized your client

$server->handleAuthorizeRequest($request, $response, true, $userid);

// this is only here so that you get to see your code in the cURL request. Otherwise, we'd redirect back to the client
$code = substr($response->getHttpHeader('Location'), strpos($response->getHttpHeader('Location'), 'code=')+5, 40);
exit("$code");

$response->send();

second try this Bat file :

set loginAPI=Elwy1
set passwordAPI=azerty
curl -X GET "http://192.168.1.14/sbauth/logout.php" -H "Cookie: PHPSESSID=uuj02arjrlts8ao37s48lkk98c"
curl -X POST "http://192.168.1.14/sbauth/login.php" -H "Cookie: PHPSESSID=uuj02arjrlts8ao37s48lkk98c" -H "Content-Type: application/x-www-form-urlencoded" --data-raw "username=%loginAPI%&password=%passwordAPI%"
For /F %%R in ('curl "http://192.168.1.14/sbauth/authorize.php?response_type=code&client_id=d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1&state=sb" -H "Referer: http://192.168.1.14/sbauth/login.php" -H "Connection: keep-alive" -H "Cookie: PHPSESSID=uuj02arjrlts8ao37s48lkk98c" -H "Upgrade-Insecure-Requests: 1"') do (set VAR=%%R)echo %VAR%
SB2.exe /connetip:192.168.1.14 /connetport:10001 /clientauthcode:%VAR% /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1



Say me if this is OK or not
 
Last edited:
@Neg035

not working for me

Code:
set loginAPI=matar
set passwordAPI=123456
curl -X GET "http://192.168.1.128/logout.php" -H "Cookie: PHPSESSID=97bue11lp68fn3seb5ph542c03"
curl -X POST "http://192.168.1.128/login.php" -H "Cookie: PHPSESSID=97bue11lp68fn3seb5ph542c03" -H 
"Content-Type: application/x-www-form-urlencoded" --data-raw "username=%loginAPI%&password=%passwordAPI%"
For /F %%R in ('curl "http://192.168.1.128/authorize.php?response_type=code&client_id=d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1&state=sb" -H 
"Referer: http://192.168.1.128/login.php" -H 
"Connection: keep-alive" -H "Cookie: PHPSESSID=97bue11lp68fn3seb5ph542c03" -H 
"Upgrade-Insecure-Requests: 1"') do (set VAR=%%R)echo %VAR%
SB.exe /connetip:192.168.1.128 /connetport:10001 /clientauthcode:%VAR% /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1
 
@Neg035

not working for me

Code:
set loginAPI=matar
set passwordAPI=123456
curl -X GET "http://192.168.1.128/logout.php" -H "Cookie: PHPSESSID=97bue11lp68fn3seb5ph542c03"
curl -X POST "http://192.168.1.128/login.php" -H "Cookie: PHPSESSID=97bue11lp68fn3seb5ph542c03" -H 
"Content-Type: application/x-www-form-urlencoded" --data-raw "username=%loginAPI%&password=%passwordAPI%"
For /F %%R in ('curl "http://192.168.1.128/authorize.php?response_type=code&client_id=d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1&state=sb" -H 
"Referer: http://192.168.1.128/login.php" -H 
"Connection: keep-alive" -H "Cookie: PHPSESSID=97bue11lp68fn3seb5ph542c03" -H 
"Upgrade-Insecure-Requests: 1"') do (set VAR=%%R)echo %VAR%
SB.exe /connetip:192.168.1.128 /connetport:10001 /clientauthcode:%VAR% /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1


remove "echo" in "do (set VAR=%%R)echo %VAR%"
works great for me.
 
Interesting situation, I tried to do registration through the domain, and new accounts appear in the database.
If I connect locally, through 192.168.1.234 - everything works. I enter a 6-digit security code and login into the server.
If I connect over the Internet, through 188.*.*.72 - It prompts me to enter the NEW 6-digit code, as if I don't have it. And then mother disconnects me from the server.

port 10001 is forwarded, which allowed at least authorization up to those 6 digits. What port do I need to forward? so that there is a connection to the database from the outside
 
This tutorial is work in progress, i will add more and more things for help create your home server for Scarlet Blade.

The game now is not finish, we are working in the client, there are issues with client in game. But the client work like 70%. The biggest issue is you cant sell/buy items, enhance it.

It will be not easy to install all parts and configure it

For help please ask in this thread : https://forum.ragezone.com/f857/scarlet-blade-server-files-client-1163598/




Prerequisites

- Windows SqlServer
- Apache/php server like Wamp

Download

Server :
Client :
Client exe SB2 (we will use SB.exe Jun 14 US) :
API :

Error

You will have many error for start all parts form the server, it will ask for DLL files, this files can be found in Microsoft Visual C++ Redistributable (version 2005-2008-2010)

Installation

Data base Account update table "tbl_WorldList" -> WorldIP and WorldIPForServer to 192.168.1.14
Data base Game update table "tbl_ZoneList" -> ZoneIP and ZoneIPForServer to 192.168.1.14


LoginServer config



The Bat file exemple for connect client to server :
SB2.exe /connetip:192.168.1.14 /connetport:10001 /clientauthcode:5529056734e4f67d82d788e01773fa1273488ab4 /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1

Hi,
Can u repost the SB2?
The link say no file... thx
This tutorial is work in progress, i will add more and more things for help create your home server for Scarlet Blade.

The game now is not finish, we are working in the client, there are issues with client in game. But the client work like 70%. The biggest issue is you cant sell/buy items, enhance it.

It will be not easy to install all parts and configure it

For help please ask in this thread : https://forum.ragezone.com/f857/scarlet-blade-server-files-client-1163598/




Prerequisites

- Windows SqlServer
- Apache/php server like Wamp

Download

Server :
Client :
Client exe SB2 (we will use SB.exe Jun 14 US) :
API :

Error

You will have many error for start all parts form the server, it will ask for DLL files, this files can be found in Microsoft Visual C++ Redistributable (version 2005-2008-2010)

Installation

Data base Account update table "tbl_WorldList" -> WorldIP and WorldIPForServer to 192.168.1.14
Data base Game update table "tbl_ZoneList" -> ZoneIP and ZoneIPForServer to 192.168.1.14


LoginServer config



The Bat file exemple for connect client to server :
SB2.exe /connetip:192.168.1.14 /connetport:10001 /clientauthcode:5529056734e4f67d82d788e01773fa1273488ab4 /clientauthid:d4e4d71b1aff496e9bedd45bf97eb9ebd63f8dfa646fbd90c1
Hi,
Can u repost SB2?
Link say no file.
I'm guessing the SB2 fixes the problem where you can't see items on character and inventory...
Thx.
 
Last edited:
client with launcher 14 years old
 
super mmorpg, I wish there was a detailed guide for the really dumb (like me) on how to set up this server. I'm already using the virtual machine option from Ashley. But starting the server and playing on 1 computer is not very convenient.
 
client with launcher 14 years old
thx for the 2014 client!!!
Do u know how to use the GM tools? did anyone post how to use?
GM Commands?
Able to get the Auto authorize to work?... I need to constantly copy and paste the code whenever I need to start the client, since the code changes each time u need to start the client...
 
thx for the 2014 client!!!
Do u know how to use the GM tools? did anyone post how to use?
GM Commands?
Able to get the Auto authorize to work?... I need to constantly copy and paste the code whenever I need to start the client, since the code changes each time u need to start the client...
unfortunately I don't understand this myself, I search for instructions, read, or torment forum participants with questions))) there is nothing special about this client, I deleted the original sb.exe and added the one that was given in the link above in this topic.
 
thx for the 2014 client!!!
Do u know how to use the GM tools? did anyone post how to use?
GM Commands?
Able to get the Auto authorize to work?... I need to constantly copy and paste the code whenever I need to start the client, since the code changes each time u need to start the client...
Open database in QueenAccount - account - security 4 and subsecurity 3
 
Last edited:
Hoping to see a composed straight forward guide between things here and ashlays for us simpletons so many changes makes me feel lost halfway as well as sb2 exe megalinks folder is empty :O
 
Just jumped back to this game after couple years, since i was around the first guys who had this files in hands but abaddoned for some reason.
Got some progress like
-Everything visible like equipments and inventory and so on
-No crash anymore in buy, sell (enchant not tested)
--But the inventory refresh only after relogin with the char.

Now working on gui to make force refresh.
 
Just jumped back to this game after couple years, since i was around the first guys who had this files in hands but abaddoned for some reason.
Got some progress like
-Everything visible like equipments and inventory and so on
-No crash anymore in buy, sell (enchant not tested)
--But the inventory refresh only after relogin with the char.

Now working on gui to make force refresh.
That would be great! After Argo Online, this was my second most popular game. I love fantasy games.
 
Back