RubyShogi 0.22 → 0.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6701c33167fe944ca928ebd9bcf6ffccda09f294a416f6dafc8730b9f668a879
4
- data.tar.gz: b8ea182ba133ac2e99f0da4d0434c7227a6f13abd2331178f179350c6c21e639
3
+ metadata.gz: 74f8307004452b06d72f5c562b3e89cc37759e4e89e59fa78806f652ff2751e7
4
+ data.tar.gz: c8bf42c7e5fb3d3e05e007c7edd996732be10db3af03cb75164d991bfbf3e3dd
5
5
  SHA512:
6
- metadata.gz: f24bf303d7e6fd9f2dd76559673bbf2eed9dff4dfe6e0a14eb6fd1e4311ea9a929522baf23b538752928047d86f641f4384f5834d14a7949f1f7641dd14169a5
7
- data.tar.gz: 4f249d08e78e8adc31476e12bdeafd49a5269739cfea6e9ff785a6ecf46cac9362986bfde156be498478af9b05bb060c88d955e04316baccdbf5be09ec7eb6ad
6
+ metadata.gz: 27000c44313e061d6afa57d318bb21887a4d7e55243f05f65c6f43db37e7bdff2044fecfb36caf06d6b6c8e98b72759319c04189ce11a72e3c9cb57122e46f48
7
+ data.tar.gz: fb54d31a0a350020d1c46fdd67d9dd99cdac9a1f71eb991bd50b4f0be310f95ed65aae49269e7cd14cc47a099ae22e555c2deab830966a4ff830eef6a7fb3084
@@ -442,7 +442,6 @@ class Board
442
442
  brd = nil
443
443
  loop do
444
444
  brd = randpos2
445
- brd2 = brd
446
445
  mgen = brd.mgen_generator
447
446
  next if mgen.checks_b? || mgen.checks_w?
448
447
  break
@@ -15,7 +15,7 @@ class Cmd
15
15
  @fen = nil
16
16
  end
17
17
 
18
- def name
18
+ def version
19
19
  puts "#{RubyShogi::NAME} v#{RubyShogi::VERSION} by #{RubyShogi::AUTHOR}"
20
20
  end
21
21
 
@@ -172,18 +172,18 @@ class Cmd
172
172
  end
173
173
 
174
174
  def help
175
- puts "Usage: ruby shuriken_ruby.rb [OPTION]... [PARAMS]..."
175
+ puts "Usage: ruby_shogi [OPTION]... [PARAMS]..."
176
176
  puts "###"
177
177
  puts "-help: This Help"
178
178
  puts "-xboard: Enter Xboard Mode"
179
179
  puts "-tactics: Run Tactics"
180
- puts "-name: Print Name Tactics"
180
+ puts "-version: Version"
181
181
  puts "-rubybench: Benchmark Ruby"
182
- puts "-bench: Benchmark ShurikenShogi Engine"
183
- puts "-mbench: Benchmark ShurikenShogi Movegen"
182
+ puts "-bench: Benchmark "
183
+ puts "-mbench: Benchmark Movegen"
184
184
  puts "-perft [NUM]: Run Perft"
185
185
  puts "-perft_by_moves [NUM]: Run Perft By Moves"
186
- puts "-profile: Profile ShurikenShogi"
186
+ puts "-profile: Profile RubyShogi"
187
187
  puts "-randommode: Activate Random Mode"
188
188
  puts "-fen [FEN]: Set Fen"
189
189
  puts "-stats [NUM]: Statistical Analysis"
@@ -204,7 +204,7 @@ class Cmd
204
204
  when "-randommode" then randommode
205
205
  when "-tactics" then tactics
206
206
  when "-test" then test
207
- when "-name" then name
207
+ when "-version" then version
208
208
  when "-fen" then fen
209
209
  when "-list" then list
210
210
  when "-profile" then profile
@@ -82,7 +82,7 @@ class Perft
82
82
  total_nodes = 0
83
83
  copy = @board
84
84
  mgen = @board.mgen_generator
85
- n, moves = 0, mgen.generate_moves
85
+ moves = mgen.generate_moves
86
86
  moves.each_with_index do |m, i|
87
87
  @board = m
88
88
  start = Time.now
@@ -142,8 +142,6 @@ class Perft
142
142
 
143
143
  def suite(depth)
144
144
  puts "~~~ suite( #{depth} ) ~~~"
145
- start = Time.now
146
- total_nodes = 0
147
145
  SUITE.each_with_index { |s, i| run_suite(s, i, depth) }
148
146
  end
149
147
  end # class Perft
@@ -40,7 +40,7 @@ $stderr.reopen("ruby_shogi-error.txt", "a+")
40
40
 
41
41
  module RubyShogi
42
42
  NAME = "RubyShogi"
43
- VERSION = "0.22"
43
+ VERSION = "0.23"
44
44
  AUTHOR = "Toni Helminen"
45
45
 
46
46
  def RubyShogi.init
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: RubyShogi
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.22'
4
+ version: '0.23'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Toni Helminen