JonasLU站主今天给大家分享一个战术小队——SQUAD的个人开服教程,本教程基于Windows2012R2服务器系统开发,推荐有一定基础的小伙伴尝试!如果你没有服务器基础但实在想开的小伙伴可以根据以下教程一步步进行操作,也可在B站观看站主配套的视频教程,如果还是有问题的欢迎到本站的论坛相关分区留言,站主会第一时间帮你解答~
架设前准备:
- 服务器系统镜像OS:Windows 2012R2服务器系统
- 另外该游戏Linux系统亦可,但是本片不讲~
- 下载SteamCMD(注意区分正版)
- 如果使用VPS云服务器推荐配置至少为2核4G/5M以上!
- 正版STEAM的游戏
- 如果懒得设置服务器安全系统,可直接方通全部端口以避免后续搜索不到服务器!(但不推荐)
- 检查安装C++所有的运行所需环境!!本站有相关检查文件免费下载!
- 推荐下载Notepad++编辑器!(本站有免费下载链接)
- 欢迎访问JonasLu.online租用站主的服务器,有任何想法也可以到本站论坛中留言!!!
下载并安装(环境包):
- 由于下载本打包文件较大,需要使用到站主搭建的云网盘下载!但如果下载失败可以自行搜索C++环境“Visual C++ Redistributable Packages”以及DX服务
- 下载完毕后,解压并输入安装包密码,找到Visual-C-Runtimes-All-in-One压缩包,进入执行install_all.bat即可!另外附带NotePad++安装包程序!
- 另外一个压缩用于修复Epic错误(可选)!可以执行EOS-SDK-CSharp.zip\SDK\Tools\EpicOnlineServicesInstaller.exe即可修复!
开始架设服务器:
- 首先需要点击下载SteamCMD,注意:网上有很多错误引导的广告!注意区分,应为全英文界面!
- 下载到任意位置即可(只要你记住)然后不要管他!默认位于“下载”中
- 随后创建一个UpdateSquad.bat文件,随后复制并保存下面的代码到该文件中:
steamcmd +login anonymous +app_update 403240 validate +quit
下载服务器
双击UpdateSquad.bat文件则开始自动下载游戏服务器(根据自己服务器的网速决定快慢)
服务端下载好后,在(默认地址C:\Users\Administrator\Downloads\steamcmd\steamapps\common\Squad Dedicated Server\SquadGame\Binaries\Win64)的目录下新建一个名为 “StartSquad.bat” 的文件,并将以下内容写入文件内:
start SquadGameServer.exe Port=6301 QueryPort=26301 RANDOM=ALWAYS -log
- 关于命令参数的解释:
- MULTIHOME = 服务器IP地址 (可选)
- Port = 游戏端口 (必要)
- QueryPort = Steam 查询端口 (必要)
- RANDOM = 地图循环方式 [ALWAYS, FIRST, NONE] (可选)
- FIXEDMAXPLAYERS = 最大玩家数量 (可选)
- FIXEDMAXTICKRATE = 服务器刷新率 [Tickrate] (可选)
- PREFERPREPROCESSOR = CPU Affinity (可选) UNTESTED
- -log = 显示日志窗口 (可选)
- -fullcrashdump = 崩溃时保存完整的服务器日志 (可选)
或者需要通过远端psexec启动(不需要则跳过这里):
echo off
echo [DEBUG] 准备使用 psexec 启动 SquadGameServer.exe
:: 注意 -i 1 表示让它运行在 Session 1(你的当前登录桌面),-d 表示不等待进程结束
:: -accepteula 是为了自动接受 EULA,避免第一次执行时卡住
:: 下面命令行需要根据你实际 PsTools 的存放位置来写
"C:\PsTools\psexec.exe" -accepteula -i 2 -d ^
"C:\Users\Administrator\Downloads\steamcmd\steamapps\common\Squad Dedicated Server\SquadGame\Binaries\Win64\SquadGameServer.exe" ^
Port=6301 QueryPort=26301 Beaconport=15000 RANDOM=ALWAYS -log
echo [DEBUG] psexec 命令执行完毕
exit
运行 StartSquad.bat” 文件,启动服务器即可!(注意检查放通端口及防火墙)
- 检查清单:
- 游戏端口 = UDP 6301 + 6302
- Steam 查询端口 = UDP & TCP 26301 + 26302
- [Windows] 允许 SquadGameServer.exe 文件通过防火墙!
- 启动服务器前请确保 Steam Client 已关闭,否则服务端无法运行。
- 当 游戏的服务端 与 游戏 在同一主机时,请先关闭 Steam 再启动服务器。 服务器启动后再登录 Steam 启动游戏,否则服务端会出错。
关于服务器配置文件:
通常情况下配置文件位于 C:\Servers\Squad\SquadGame\ServerConfig\
中,下面是文件的简单介绍:
Admins.cfg # DEV权限组[管理员]
Bans.cfg # 封禁玩家列表
License.cfg # 许可证(要申请才能进入官方服务器列表哦!)
MapRotation.cfg # 地图循环列表
MOTD.cfg # 服务器介绍[每日消息]
Rcon.cfg # 远程管理配置(可选)
RemoteAdminListHosts.cfg # 远程权限组[管理员]列表(可选)
RemoteBanListHosts.cfg # 远程封禁玩家列表(可选)
Server.cfg # 服务器配置(重要)
ServerMessages.cfg # 服务器循环[红字]公告
权限组[管理员]文件
文件名:Admins.cfg
可以创建一个 权限组,并将管理员分配到该组中。可以创建任意类型,及任意数量的权限组如下。
Group=SuperAdmin:changemap,cheat,private,balance,chat,kick,ban,config,cameraman,debug,pause
Group=Admin:changemap,balance,chat,kick,ban,cameraman,pause
Group=Moderator:changemap,chat,kick,ban
Group=Whitelist:reserve
//实习管理员
Admin=76561115695178:Moderator //玩家 5
Admin=8915618948911:Moderator //玩家 4
//管理员
Admin=7894591951519:Admin //玩家 3
Admin=7895365435431:Admin //玩家 8792
//白名单 - VIP&SVIP
Admin=7984591565611:Whitelist //玩家 123
Admin=7984591565523:Whitelist //玩家 156
相关命令解释:
权限列表
changemap # 更换/预设地图
pause # 暂停游戏
cheat # 使用作弊命令
private # 设置服务器密码
balance # 忽略服务器阵营平衡
chat # 管理员聊天/服务器公告
kick # 踢出玩家
ban # 封禁玩家
config # 更改服务器配置
cameraman # 摄影机 - 管理员视角
immune # 无法被 踢出/封禁
manageserver # 关闭服务器
reserve # 预留位
debug # 调试
teamchange # 忽略更换阵营时间限制
forceteamchange # 允许执行强制更换阵营命令
canseeadminchat # 查看 管理员聊天/友军击杀/管理员加入 消息
封禁玩家_Bans.cfg
这个文件储存的是封禁玩家列表,格式为:SteamID64:封禁时间戳 //备注
, 手动添加封禁玩家时,请使用 换行符作为每个封禁玩家的分割。
76561198039509812:0 //永久封禁-使用作弊程序
7862895148978485:1623366856 //击杀友军
服务器介绍_文件名:MOTD.cfg
MOTD.cfg 支持两个 HTML 标记:
<a>黄色字体</a> <a href="link.com">黄色字体链接</a>
服务器配置主文件:
文件名:Server.cfg
这个文件储存的是常规的服务器配置,新添加的内容请前往 官方Wiki/en 更新。因此如果想更改默认值,您需要手动把配置项添加到现有服务器配置中。
- 如果服务器名称的特殊字符在 服务器列表 中显示为 “?????”,解决方法:将特殊字符粘贴到文本编辑器,然后再复制到配置文件。示例:
ServerName="Test Server Λ"
. - AutoTkBanTime: 此选项可用于在服务器玩家击杀7个友军时,自动封禁的时间秒数。例子: AutoTkBanTime=1209600 封禁玩家 14 天
- PublicQueueLimit: Cap public queue. Standard is PublicQueueLimit=25 and this cap the public queue to 25. =0 means that there wont be public queue. =-1 is unlimited queue.
- 如果懒得配置,复制下面站主的配置文件,对服务器的名字修改即可!
ServerName="[ENG/CN]ALL_Welcome/BotsAI_PVE/JonasLu.com"
// Control visibility in the server browser
ShouldAdvertise=true
// Set the server to LAN mode
IsLANMatch=false
// Max player count on the server
MaxPlayers=80
// Number of reserved slots for admins / members
NumReservedSlots=2
// Size of the server queuing, for regular user
PublicQueueLimit=5
// Once a player has been accepted from the queue and is joining the server, this is the time they have to fully connect before their spot is given to another player
JoiningPlayerTimeout=360
// Tags for server exposure
// Use space as a delimiter, e.g.
// Tags=language_en language_nl mode_aas mode_raas mode_invasion playstyle_relaxed exp_experience maprot_voting
// For more information and the full list of tags please refer to https://squad.fandom.com/wiki/Server_Configuration#Tag_System
Tags=language_en language_zh exp_newplayer
// Rules for server in tags form
// Use space as a delimiter, e.g.
//Rules=rule_vehicle_name_claim rule_play_objective rule_no_main_camping rule_no_soloing_vehicle rule_mech_inf_restrictions rule_lock_restrictions
// For more information and the full list of rule tags please refer to https://squad.fandom.com/wiki/Server_Configuration#Rule_List
Rules=rule_no_main_camping rule_vehicle_fcfs
// Map rotation mode: it can be
// LevelList(use order in level rotation config file)
// LayerList (use order in layer rotation config file)
// LayerList_Vote (presents vote screen on the end of match)
// or
// LevelList_Randomized
// LayerList_Randomized
// which are randomized version of previous options
MapRotationMode=LayerList_Vote
// Should the Map/Layer rotations list be randomized at start?
RandomizeAtStart=true
// Should Faction be voted for on generic layers? Randomized if false.
UseVoteFactions=false
// Should next Map be voted for at end of round?
UseVoteLevel=false
// Should next Layer be voted for at end of round?
UseVoteLayer=false
// Completly Allow or Disallow Team change to all players. Only user with Level_Balance access level can bypass this flag
AllowTeamChanges=true
// If set to false, players can change teams regardless of team balance. Otherwise, the NumPlayersDiffForTeamChanges Value is used
PreventTeamChangeIfUnbalanced=true
// Maximum Allowed difference in player count between teams. This takes into account the team the player leaves and the team the player joins
NumPlayersDiffForTeamChanges=3
RejoinSquadDelayAfterKick=360
RecordDemos=false
// Whether public clients are allowed to record.
// If you do not want public clients to record, but you do want to allow certain ones to, you can give the admin access level "ClientDemos".
// There is a difference between "ClientDemos" and "Demos". "Demos" allows access to server commands for recording server-sided demos, while "ClientDemos" only allows clientside demos (no admin commands)
AllowPublicClientsToRecord=false
ServerMessageInterval=300
// Forces the server to do non-seamless travel (disconnect when changing maps) every X seconds
// ForceNonSeamlessTravelIntervalSeconds=43200
// The following are required for Licensed servers, but can be changed for non-licensed servers
TKAutoKickEnabled=true
AutoTKBanNumberTKs=10
AutoTKBanTime=300
VehicleKitRequirementDisabled=false
AllowCommunityAdminAccess=true
// End round timer before we move to next match in case when voting is OFF
TimeBetweenMatches=45
// For how long end screen will be displayed before we move to voting
TimeBeforeVote=60
// Only Offworld Industries developers are admins
AllowDevProfiling=true
AllowQA=true
// The below commands are optional for all servers
VehicleClaimingDisabled=false
剩下文件就需要大家自己去尝试了,重要的文件已经全部讲解!本片亦参考官方的WIKI,大家也可自行查询相关讲解!
如果大家想申请认证服务器则需要到这个网站提交申请:OWI – License Server
但是注意:申请较为严格,大家不要盲目申请!需要有一个良好的服务器和运营能力!!
另外!站主JonasLU的服务器租用网站!
由于不少小伙伴确实搞不太明白或着认为太麻烦的,私信留言希望站主可以帮忙开服务器,这里站住特意开发了一个网站用于大家租用服务器!但是目前站主这里只提供少量的服务器,所有大家先到先得哦~
欢迎访问JonasLu.online租用站主的服务器,有任何想法也可以到本站论坛中留言!!!

关于作者