gamefic-tty 3.0.0 → 3.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rspec.yml +1 -1
- data/CHANGELOG.md +3 -0
- data/Gemfile +4 -4
- data/lib/gamefic-tty/user.rb +2 -2
- data/lib/gamefic-tty/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ac6d80d81bfdeb6188299d401d4e728585cbf02143eb78685c9d1b4c24fc7d66
|
4
|
+
data.tar.gz: 89187ba8fb00f0bb105bbb2418836efe24b003c77c4b30e1b3d511609da11870
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2b03ed10e8d213f68d3de7eab1425e234b2bbdfdc95bf3c9da4e3095645c5944424979fa964c75fbf0089d225f5896149c1dbab63acec7c79cf5d5c680910658
|
7
|
+
data.tar.gz: 8710c4cbc2d574acc8ef82d4884fc5b19a3c0554293b0cbe634737b384292a8dbcee1df9a67d830901fbc7c1586a7b9f20f65f3f7ec795b8d12bf0ec38c6cfb8
|
data/.github/workflows/rspec.yml
CHANGED
data/CHANGELOG.md
CHANGED
data/Gemfile
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
source "https://rubygems.org"
|
2
|
-
|
3
|
-
# Specify your gem's dependencies in gamefic-tty.gemspec
|
4
|
-
gemspec
|
1
|
+
source "https://rubygems.org"
|
2
|
+
|
3
|
+
# Specify your gem's dependencies in gamefic-tty.gemspec
|
4
|
+
gemspec
|
data/lib/gamefic-tty/user.rb
CHANGED
@@ -21,7 +21,7 @@ module Gamefic
|
|
21
21
|
|
22
22
|
# Update the user with a hash of data representing the current game state.
|
23
23
|
#
|
24
|
-
# @param
|
24
|
+
# @param state [Hash]
|
25
25
|
# @return [void]
|
26
26
|
def update state
|
27
27
|
@output.write state_to_text(state)
|
@@ -29,7 +29,7 @@ module Gamefic
|
|
29
29
|
|
30
30
|
def state_to_text state
|
31
31
|
output = state[:messages].to_s
|
32
|
-
unless state[:options].nil?
|
32
|
+
unless state[:options].nil? || state[:options].empty?
|
33
33
|
list = '<ol class="multiple_choice">'
|
34
34
|
state[:options].each { |o|
|
35
35
|
list += "<li><a href=\"#\" rel=\"gamefic\" data-command=\"#{o}\">#{o}</a></li>"
|
data/lib/gamefic-tty/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gamefic-tty
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fred Snyder
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-09-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gamefic
|