palworld_rcon 0.1.0 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: edf9612a8d262bd8711f89f26188e06ec6bd2a952816f5969109e1bfd03b3475
4
- data.tar.gz: bc890a53c5317ca5a1d7f78c60c4343241e16189eab9f50fe09e6b874573158f
3
+ metadata.gz: ea6a34916bb20565e148c29507b9eeebbac568c22ac38542118e722c73646e2d
4
+ data.tar.gz: 5fb29be482bf73fc1fe7e08a7acc3606fd4d80974c7c9ca83b848095f58a5b4e
5
5
  SHA512:
6
- metadata.gz: 3023b5e9be0c0691622a6d4ee932de2882ad9bac04165c9d8efdb0433b3206ad9ad77f39ef160c9138ae94f9ca2e4688a5a3a84ea19ad83d8be15011583e6fcf
7
- data.tar.gz: 7793a1b4100a4dc2845c89acfba68c0ddbe147a3efc268e00f539f7cf9bacc08510f13f8364d862d979f98bb1a17bb1eb12cc9a57af3e400ee54763526b3b12d
6
+ metadata.gz: b780d1bf6bab20ddc3cf106128f01ec4e8a2109ae747a6614c2693527edc4ecca643850d3907d81f28634b0f3dfdb0a7b2760683573ed98013ff96abf101afea
7
+ data.tar.gz: 331db935cd591f7dd0ce2c9a2e0107f124a756676d4cb5fad20f4aca1b54fe95edf1ea337bea6ad10f55b014ba18084599da3bb7fdbd08fc0cdd83a47af953f4
data/CHANGELOG.md CHANGED
@@ -3,3 +3,15 @@
3
3
  ## [0.1.0] - 2024-01-29
4
4
 
5
5
  - Initial release
6
+
7
+ ## [0.1.1] - 2024-01-29
8
+
9
+ - Replenish commands
10
+
11
+ ## [0.1.2] - 2024-01-29
12
+
13
+ - Fix gemfile.lock issue
14
+
15
+ ## [0.1.3] - 2024-02-02
16
+
17
+ - Fix message cut off because of spaces
data/README.md CHANGED
@@ -1,18 +1,16 @@
1
1
  # PalworldRcon
2
2
 
3
- TODO: Delete this and the text below, and describe your gem
4
-
5
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/palworld_rcon`. To experiment with that code, run `bin/console` for an interactive prompt.
3
+ A ruby Palworld RCON client.
6
4
 
7
5
  ## Installation
8
6
 
9
7
  Install the gem and add to the application's Gemfile by executing:
10
8
 
11
- $ bundle add UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG
9
+ $ bundle add palworld_rcon
12
10
 
13
11
  If bundler is not being used to manage dependencies, install the gem by executing:
14
12
 
15
- $ gem install UPDATE_WITH_YOUR_GEM_NAME_PRIOR_TO_RELEASE_TO_RUBYGEMS_ORG
13
+ $ gem install palworld_rcon
16
14
 
17
15
  ## Usage
18
16
 
@@ -12,7 +12,7 @@ module PalworldRcon
12
12
  end
13
13
 
14
14
  def broadcast(message)
15
- cmd = "Broadcast #{message}"
15
+ cmd = "Broadcast #{process_message(message)}"
16
16
  execute_command(cmd)
17
17
  end
18
18
 
@@ -30,6 +30,22 @@ module PalworldRcon
30
30
  execute_command("ShowPlayers")
31
31
  end
32
32
 
33
+ def shutdown(count_down, message)
34
+ execute_command("Shutdown #{count_down} #{process_message(message)}")
35
+ end
36
+
37
+ def save
38
+ execute_command("Save")
39
+ end
40
+
41
+ def server_info
42
+ execute_command("Info")
43
+ end
44
+
45
+ def do_exit
46
+ execute_command("DoExit")
47
+ end
48
+
33
49
  private
34
50
 
35
51
  def execute_command(cmd)
@@ -38,6 +54,10 @@ module PalworldRcon
38
54
  raise ExectueCommandError, e.message
39
55
  end
40
56
 
57
+ def process_message(message)
58
+ message.gsub(" ", "_")
59
+ end
60
+
41
61
  attr_reader :rcon_client
42
62
  end
43
63
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PalworldRcon
4
- VERSION = "0.1.0"
4
+ VERSION = "0.1.3"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: palworld_rcon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - uooobarry
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-01-29 00:00:00.000000000 Z
11
+ date: 2024-02-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rconrb