Added capability to specify arguments to PocketMine.php when running start.ps1

Example: .\start.ps1 --disable-ansi --debug.level=2
This commit is contained in:
Dylan K. Taylor 2017-09-09 18:44:18 +01:00
parent 17d949f476
commit 8c363cb571

View File

@ -1,6 +1,8 @@
param (
[CmdletBinding(PositionalBinding=$false)]
param (
[string]$php = "",
[switch]$Loop = $false
[switch]$Loop = $false,
[string][Parameter(ValueFromRemainingArguments)]$extraPocketMineArgs
)
if($php -ne ""){
@ -23,7 +25,7 @@ if(Test-Path "PocketMine-MP.phar"){
}
function StartServer{
$command = "powershell " + $binary + " " + $file + " --enable-ansi"
$command = "powershell " + $binary + " " + $file + " --enable-ansi " + $extraPocketMineArgs
iex $command
}