宁哥WD手游linux教程
----------------------------------------------------------------------------------------------------
linux7.2 64
----------------------------------------------------------------------------------------------------
安装宝塔
yum install -y wget && wget -O install.sh http://download.bt.cn/install/install.sh && sh install.sh
----------------------------------------------------------------------------------------------------
安装数据库,开放端口1:65535
----------------------------------------------------------------------------------------------------
关闭防火墙
systemctl status firewalld
systemctl stop firewalld
systemctl disable firewalld
数据库密码默认:123456
要修改打开
\BOOT-INF\lib\game-db-0.1.0.jar
application-db.yml
修改 数据库密码
----------------------------------------------------------------------------------------------------
mysql -u root -p123456
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION;
FLUSH PRIVILEGES;
quit;
用n++连接数据库
新建gserver
导入gserver.sql
----------------------------------------------------------------------------------------------------
配置java环境
----------------------------------------------------------------------------------------------------
上传 jdk-8u144-linux-x64.rpm 到根目录下
cd /
rpm -ivh jdk-8u144-linux-x64.rpm
在更改/etc/profile后面加上下面这句
#java
export LANG=en_US.UTF8
export JAVA_HOME=/usr/java/jdk1.8.0_111
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
yum install screen
----------------------------------------------------------------------------------------------------
服务端修改
----------------------------------------------------------------------------------------------------
安装notepad,winrar,
\BOOT-INF\classes\application.yml
修改 IP
\BOOT-INF\lib\game.jar
\static\vip4\mobile\sdk\js\login.js
修改 IP
\BOOT-INF\lib\game.jar
\static\vip4\atm\g-bits\patch.zip
\static\vip4\atm\g-bits\patch\patch\dist.lua
修改 区名和IP
用WINRAR打开 game.jar
application.yml导入替换
game-api-0.1.0.jar拖进去 文件 不压缩导入 复制文件名
----------------------------------------------------------------------------------------------------
上传服务端 并启动
----------------------------------------------------------------------------------------------------
上传改好的game.jar包到home目录下
添加权限
chmod -R 777 /home
启动服务端
screen
cd /home
java -jar game.jar &
出现
GameCore - game init over
表示启动成功!
----------------------------------------------------------------------------------------------------
如果端口被占用
查看占用端口进程
ss -lntpd | grep :81
杀死进程
kill XXXXX
----------------------------------------------------------------------------------------------------
客户端修改
----------------------------------------------------------------------------------------------------
使用改之里反编译修改(没用过的先配置JDK)
\assets\res
PlatformConfig.luac
修改IP
\assets\
sdkConfig.properties
修改 wd=修改好的加密码
打开加密工具,复制明文代码,修改IP,再加密
----------------------------------------------------------------------------------------------------
打开游戏之后,注册账号,验证码随便写4位数
----------------------------------------------------------------------------------------------------
|
|