sc2ai 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/docker_build/Dockerfile.ruby +2 -2
- data/lib/sc2ai/connection.rb +1 -2
- data/lib/sc2ai/local_play/client/configurable_options.rb +6 -7
- data/lib/sc2ai/local_play/client.rb +1 -1
- data/lib/sc2ai/version.rb +1 -1
- data/sig/sc2ai.rbs +3 -3
- metadata +22 -38
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f0b6225d7a28ee6656744623ee50db7cfa997712ecbe357a3e39f903e4023c0f
|
4
|
+
data.tar.gz: 60f588720e52e4881a10d0b232754ca0b532aa44b90810f650a156e265c309ba
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 65249c7a5f036e9d15286dc3d851ec3b9ebf2a50e1978d1d305476d9e0d69597e0a97504af98b387b718cf5bc2aed581b97dae51b202f10fe174c8be3e9d03d1
|
7
|
+
data.tar.gz: 2e746b39d4dc86e257f28905ee2085e92a980aa51035dc75051b61830f9bcd5e197e0377c7ca4265a59e843fd339bff454c522c212480bfe93f6c9525599e8ed
|
@@ -4,7 +4,7 @@ LABEL service="bot-ruby-local"
|
|
4
4
|
USER root
|
5
5
|
WORKDIR /root/ruby-builder
|
6
6
|
|
7
|
-
ARG RUBY_VERSION=3.
|
7
|
+
ARG RUBY_VERSION=3.4.1
|
8
8
|
ARG DEBIAN_DISABLE_RUBYGEMS_INTEGRATION=true
|
9
9
|
|
10
10
|
# Deps - Ruby build
|
@@ -17,7 +17,7 @@ RUN tar -zxf yaml-0.2.5.tar.gz
|
|
17
17
|
|
18
18
|
# Ruby
|
19
19
|
RUN mkdir -p /root/ruby-builder/.ruby
|
20
|
-
RUN curl https://cache.ruby-lang.org/pub/ruby/3.
|
20
|
+
RUN curl https://cache.ruby-lang.org/pub/ruby/3.4/ruby-$RUBY_VERSION.tar.gz -o ruby-$RUBY_VERSION.tar.gz
|
21
21
|
RUN tar -zxf ruby-$RUBY_VERSION.tar.gz
|
22
22
|
RUN mkdir ruby-$RUBY_VERSION/build
|
23
23
|
WORKDIR /root/ruby-builder/ruby-$RUBY_VERSION/build
|
data/lib/sc2ai/connection.rb
CHANGED
@@ -54,9 +54,8 @@ module Sc2
|
|
54
54
|
# do initial ping to ensure status is set and connection is working
|
55
55
|
response_ping = ping
|
56
56
|
Sc2.logger.debug { "Game version: #{response_ping.game_version}" }
|
57
|
-
rescue Errno::ECONNREFUSED, Errno::ECONNRESET
|
57
|
+
rescue Errno::ECONNREFUSED, Errno::ECONNRESET, Errno::EADDRNOTAVAIL
|
58
58
|
raise Error, "Connection timeout. Max retry exceeded." unless (attempt += 1) < 30 # 30s attempts
|
59
|
-
|
60
59
|
@listeners[ConnectionListener.name]&.each { _1.on_connection_waiting(self) }
|
61
60
|
sleep(1)
|
62
61
|
retry
|
@@ -5,9 +5,9 @@ module Sc2
|
|
5
5
|
# Attributes shared by Configuration and Client
|
6
6
|
module ConfigurableOptions
|
7
7
|
# @!attribute host
|
8
|
-
# Sc2 host param on which to listen for connections, default '
|
8
|
+
# Sc2 host param on which to listen for connections, default '127.0.0.1'
|
9
9
|
#
|
10
|
-
# Launch param: -host
|
10
|
+
# Launch param: -host 127.0.0.1
|
11
11
|
# @return [String,nil]
|
12
12
|
attr_accessor :host
|
13
13
|
|
@@ -88,11 +88,10 @@ module Sc2
|
|
88
88
|
|
89
89
|
# Resets configurable launch options to their defaults
|
90
90
|
def load_default_launch_options
|
91
|
-
@host =
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
@host = "127.0.0.1"
|
91
|
+
@host = if Paths.wsl?
|
92
|
+
"#{Socket.gethostname}.mshome.net"
|
93
|
+
else
|
94
|
+
"127.0.0.1" # -listen
|
96
95
|
end
|
97
96
|
|
98
97
|
@display_mode = 0 # -displayMode
|
@@ -31,7 +31,7 @@ module Sc2
|
|
31
31
|
end
|
32
32
|
|
33
33
|
# Initialize new Sc2 client (starts with #launch)
|
34
|
-
# @param host [String] to listen on, i.e. "
|
34
|
+
# @param host [String] to listen on, i.e. "127.0.0.1"
|
35
35
|
# @param port [Integer] 5001
|
36
36
|
# @param options [Hash] (see Sc2::Client::ConfigurableOptions)
|
37
37
|
def initialize(host:, port:, **options)
|
data/lib/sc2ai/version.rb
CHANGED
data/sig/sc2ai.rbs
CHANGED
@@ -3872,7 +3872,7 @@ module Sc2
|
|
3872
3872
|
|
3873
3873
|
# Initialize new Sc2 client (starts with #launch)
|
3874
3874
|
#
|
3875
|
-
# _@param_ `host` — to listen on, i.e. "
|
3875
|
+
# _@param_ `host` — to listen on, i.e. "127.0.0.1"
|
3876
3876
|
#
|
3877
3877
|
# _@param_ `port` — 5001
|
3878
3878
|
#
|
@@ -3936,9 +3936,9 @@ module Sc2
|
|
3936
3936
|
# Resets configurable launch options to their defaults
|
3937
3937
|
def load_default_launch_options: () -> untyped
|
3938
3938
|
|
3939
|
-
# Sc2 host param on which to listen for connections, default '
|
3939
|
+
# Sc2 host param on which to listen for connections, default '127.0.0.1'
|
3940
3940
|
#
|
3941
|
-
# Launch param: -host
|
3941
|
+
# Launch param: -host 127.0.0.1
|
3942
3942
|
attr_accessor host: String?
|
3943
3943
|
|
3944
3944
|
# Override the path to find the data package.
|
metadata
CHANGED
@@ -1,14 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sc2ai
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dyson Returns
|
8
|
-
autorequire:
|
9
8
|
bindir: exe
|
10
9
|
cert_chain: []
|
11
|
-
date:
|
10
|
+
date: 2025-01-11 00:00:00.000000000 Z
|
12
11
|
dependencies:
|
13
12
|
- !ruby/object:Gem::Dependency
|
14
13
|
name: async
|
@@ -100,28 +99,14 @@ dependencies:
|
|
100
99
|
requirements:
|
101
100
|
- - "~>"
|
102
101
|
- !ruby/object:Gem::Version
|
103
|
-
version: '0
|
102
|
+
version: '1.0'
|
104
103
|
type: :runtime
|
105
104
|
prerelease: false
|
106
105
|
version_requirements: !ruby/object:Gem::Requirement
|
107
106
|
requirements:
|
108
107
|
- - "~>"
|
109
108
|
- !ruby/object:Gem::Version
|
110
|
-
version: '0
|
111
|
-
- !ruby/object:Gem::Dependency
|
112
|
-
name: csv
|
113
|
-
requirement: !ruby/object:Gem::Requirement
|
114
|
-
requirements:
|
115
|
-
- - ">="
|
116
|
-
- !ruby/object:Gem::Version
|
117
|
-
version: '0'
|
118
|
-
type: :runtime
|
119
|
-
prerelease: false
|
120
|
-
version_requirements: !ruby/object:Gem::Requirement
|
121
|
-
requirements:
|
122
|
-
- - ">="
|
123
|
-
- !ruby/object:Gem::Version
|
124
|
-
version: '0'
|
109
|
+
version: '1.0'
|
125
110
|
- !ruby/object:Gem::Dependency
|
126
111
|
name: sc2ai-kdtree
|
127
112
|
requirement: !ruby/object:Gem::Requirement
|
@@ -156,14 +141,14 @@ dependencies:
|
|
156
141
|
requirements:
|
157
142
|
- - "~>"
|
158
143
|
- !ruby/object:Gem::Version
|
159
|
-
version: 0.9.
|
144
|
+
version: 0.9.37
|
160
145
|
type: :development
|
161
146
|
prerelease: false
|
162
147
|
version_requirements: !ruby/object:Gem::Requirement
|
163
148
|
requirements:
|
164
149
|
- - "~>"
|
165
150
|
- !ruby/object:Gem::Version
|
166
|
-
version: 0.9.
|
151
|
+
version: 0.9.37
|
167
152
|
- !ruby/object:Gem::Dependency
|
168
153
|
name: abbrev
|
169
154
|
requirement: !ruby/object:Gem::Requirement
|
@@ -198,28 +183,28 @@ dependencies:
|
|
198
183
|
requirements:
|
199
184
|
- - "~>"
|
200
185
|
- !ruby/object:Gem::Version
|
201
|
-
version: '1.
|
186
|
+
version: '1.9'
|
202
187
|
type: :development
|
203
188
|
prerelease: false
|
204
189
|
version_requirements: !ruby/object:Gem::Requirement
|
205
190
|
requirements:
|
206
191
|
- - "~>"
|
207
192
|
- !ruby/object:Gem::Version
|
208
|
-
version: '1.
|
193
|
+
version: '1.9'
|
209
194
|
- !ruby/object:Gem::Dependency
|
210
195
|
name: sord
|
211
196
|
requirement: !ruby/object:Gem::Requirement
|
212
197
|
requirements:
|
213
|
-
- - "
|
198
|
+
- - "~>"
|
214
199
|
- !ruby/object:Gem::Version
|
215
|
-
version: '0'
|
200
|
+
version: '6.0'
|
216
201
|
type: :development
|
217
202
|
prerelease: false
|
218
203
|
version_requirements: !ruby/object:Gem::Requirement
|
219
204
|
requirements:
|
220
|
-
- - "
|
205
|
+
- - "~>"
|
221
206
|
- !ruby/object:Gem::Version
|
222
|
-
version: '0'
|
207
|
+
version: '6.0'
|
223
208
|
- !ruby/object:Gem::Dependency
|
224
209
|
name: standard
|
225
210
|
requirement: !ruby/object:Gem::Requirement
|
@@ -306,7 +291,6 @@ dependencies:
|
|
306
291
|
version: '0'
|
307
292
|
description: This is a Ruby interface to STARCRAFT® II. Write your own AI using an
|
308
293
|
easy interface and compete against others.
|
309
|
-
email:
|
310
294
|
executables:
|
311
295
|
- sc2ai
|
312
296
|
extensions: []
|
@@ -416,13 +400,14 @@ metadata:
|
|
416
400
|
homepage_uri: https://sc2ai.pages.dev/
|
417
401
|
source_code_uri: https://gitlab.com/dysonreturns/sc2ai
|
418
402
|
changelog_uri: https://sc2ai.pages.dev/file.CHANGELOG
|
419
|
-
post_install_message: "BREAKING CHANGE:
|
420
|
-
are now capitalized, i.e.\n\e[1;91m:Air\e[0m is now \e[1;92m:AIR\e[0m,
|
421
|
-
is now \e[1;92mApi::Race::ZERG\e[0m, etc.\nThe mild
|
422
|
-
\
|
423
|
-
\
|
424
|
-
\
|
425
|
-
\
|
403
|
+
post_install_message: "BREAKING CHANGE: Version 0.3.0 upgraded to protoboeuf.\nApi
|
404
|
+
constants are now capitalized, i.e.\n\e[1;91m:Air\e[0m is now \e[1;92m:AIR\e[0m,
|
405
|
+
\e[1;91mApi::Race::Zerg\e[0m is now \e[1;92mApi::Race::ZERG\e[0m, etc.\nThe mild
|
406
|
+
refactor is worth the speed.\n\n %@@% CHECK\n %++++% YOUR\n *+**++
|
407
|
+
\ ENUMS!\n %*+#\n *@#***%%\n #%@%*++%%%%%\n %%%@%%%%%%%%%%\n %%@%%%%%%%%@%%\n
|
408
|
+
\ ++*@@%%%%%%@+**\n *+*%@@%%%%%%@#**\n *+*@@%%%%%%%@ **\n *+@@@@%%%%@@*+\n
|
409
|
+
\ *+@@@@@@@@*+\n %@++++%@@+*%#\n %@@@***@#++*%%%\n %%%@@@@++@@@@@@%#\n @@@@@
|
410
|
+
\ @@@%%\n@@@@@ @@@@=\n"
|
426
411
|
rdoc_options: []
|
427
412
|
require_paths:
|
428
413
|
- lib
|
@@ -430,15 +415,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
430
415
|
requirements:
|
431
416
|
- - ">="
|
432
417
|
- !ruby/object:Gem::Version
|
433
|
-
version: 3.
|
418
|
+
version: 3.3.6
|
434
419
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
435
420
|
requirements:
|
436
421
|
- - ">="
|
437
422
|
- !ruby/object:Gem::Version
|
438
423
|
version: '0'
|
439
424
|
requirements: []
|
440
|
-
rubygems_version: 3.
|
441
|
-
signing_key:
|
425
|
+
rubygems_version: 3.6.2
|
442
426
|
specification_version: 4
|
443
427
|
summary: STARCRAFT® II AI API
|
444
428
|
test_files: []
|