chingu 0.9rc1 → 0.9rc2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +26 -0
- data/Rakefile +2 -1
- data/chingu.gemspec +8 -7
- data/lib/chingu.rb +1 -1
- data/lib/chingu/core_ext/array.rb +10 -19
- data/lib/chingu/game_states/network_client.rb +24 -12
- data/lib/chingu/game_states/network_server.rb +14 -14
- data/lib/chingu/simple_menu.rb +3 -3
- data/spec/chingu/network_spec.rb +78 -0
- metadata +74 -100
data/README.rdoc
CHANGED
@@ -26,6 +26,7 @@ There's also more complex examples, like a clone of Conways game of life (http:/
|
|
26
26
|
|
27
27
|
== PROJECTS USING CHINGU
|
28
28
|
Links to some of the projects using/depending on Chingu:
|
29
|
+
* https://github.com/Spooner/wrath (pixely 2-player action adventure in development)
|
29
30
|
* http://ippa.se/games/unexpected_outcome.zip (LD#19 game compo entry by ippa)
|
30
31
|
* https://bitbucket.org/philomory/ld19/ (LD#19 game compo entry by philomory)
|
31
32
|
* https://github.com/Spooner/fidgit (GUI-lib )
|
@@ -110,6 +111,8 @@ An "@image = @animation.next" in your Player#update is usually enough to get you
|
|
110
111
|
|
111
112
|
=== Chingu::Parallax
|
112
113
|
A class for easy parallaxscrolling. Add layers with different damping, move the camera to generate a new snapshot. See example3.rb for more.
|
114
|
+
NOTE: Doing Parallax.create when using a trait viewport will give bad results.
|
115
|
+
If you need parallax together with viewport do Parallax.new and then manually doing parallax.update/draw.
|
113
116
|
|
114
117
|
=== Chingu::HighScoreList
|
115
118
|
A class to keep track of high scores, limit the list, automatic sorting on score, save/load to disc. See example13.rb for more.
|
@@ -478,6 +481,8 @@ Or Chingus shortcut:
|
|
478
481
|
|
479
482
|
Chingus inputhandler will detect that Menu is a GameState-class, create a new instance and activate it with push_game_state().
|
480
483
|
|
484
|
+
GOTCHA: Currently you can't switch to a new game state from Within GameState#initialize() or GameState#setup()
|
485
|
+
|
481
486
|
=== Premade game states
|
482
487
|
Chingu comes with some pre-made game states.
|
483
488
|
A simple but usefull one is GameStates::Pause. Once pushed it will draw the previous game state but not update it --
|
@@ -747,6 +752,9 @@ This is great for scrolling games. You also have:
|
|
747
752
|
viewport.lag = 0.95 # Set a lag-factor to use in combination with x_target / y_target
|
748
753
|
viewport.x_target = 100 # This will move viewport towards X-coordinate 100, the speed is determined by the lag-parameter.
|
749
754
|
|
755
|
+
NOTE: Doing Parallax.create when using a trait viewport will give bad results.
|
756
|
+
If you need parallax together with viewport do Parallax.new and then manually doing parallax.update/draw.
|
757
|
+
|
750
758
|
==== Trait "collision_detection"
|
751
759
|
Adds class and instance methods for basic collision detection.
|
752
760
|
|
@@ -861,6 +869,24 @@ It's not only that the second example is readable by ppl now even familiar with
|
|
861
869
|
Set a new x or angle or color and it will instantly update on screen.
|
862
870
|
|
863
871
|
|
872
|
+
== DEPRECATIONS
|
873
|
+
Chingu (as all libraries) will sometimes break an old API. Naturally we try to not do this, but sometimes it's nessesary
|
874
|
+
to take the library forward. If your old game stops working with a new chingu it could depend on some of the following:
|
875
|
+
|
876
|
+
Listing game objects:
|
877
|
+
class Enemy < GameObject; end;
|
878
|
+
class Troll < Enemy; end;
|
879
|
+
class Witch < Enemy; end;
|
880
|
+
|
881
|
+
Chingu 0.7
|
882
|
+
Enemy.all # Will list objects created with Enemy.create, Troll.create, Witch.create
|
883
|
+
|
884
|
+
Chingu ~0.8+
|
885
|
+
Enemy.all # list only list objects created with Enemy.create
|
886
|
+
|
887
|
+
We gained a lot of speed breaking that API.
|
888
|
+
|
889
|
+
|
864
890
|
== MISC / FAQ
|
865
891
|
=== How do I access my main-window easily?
|
866
892
|
Chingu keeps a global variable, $window, which contains the Chingu::Window instance.
|
data/Rakefile
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require 'rubygems'
|
2
|
+
require 'psych'
|
2
3
|
require File.dirname(__FILE__) + '/lib/chingu'
|
3
4
|
include Chingu
|
4
5
|
|
@@ -14,7 +15,7 @@ begin
|
|
14
15
|
gemspec.rubyforge_project = "chingu"
|
15
16
|
gemspec.version = Chingu::VERSION
|
16
17
|
|
17
|
-
gemspec.add_dependency 'gosu', '>= 0.7.27'
|
18
|
+
gemspec.add_dependency 'gosu', '>= 0.7.27.1'
|
18
19
|
gemspec.add_dependency 'rest-client'
|
19
20
|
gemspec.add_dependency 'crack'
|
20
21
|
gemspec.add_development_dependency 'rspec', '>= 2.1.0'
|
data/chingu.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{chingu}
|
8
|
-
s.version = "0.
|
8
|
+
s.version = "0.9rc2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new("> 1.3.1") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["ippa"]
|
12
|
-
s.date = %q{2011-02-
|
12
|
+
s.date = %q{2011-02-26}
|
13
13
|
s.description = %q{OpenGL accelerated 2D game framework for Ruby. Builds on Gosu (Ruby/C++) which provides all the core functionality. Chingu adds simple yet powerful game states, prettier input handling, deployment safe asset-handling, a basic re-usable game object and stackable game logic.}
|
14
14
|
s.email = %q{ippa@rubylicio.us}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -199,6 +199,7 @@ Gem::Specification.new do |s|
|
|
199
199
|
"spec/chingu/images/rect_20x20.png",
|
200
200
|
"spec/chingu/inflector_spec.rb",
|
201
201
|
"spec/chingu/input_spec.rb",
|
202
|
+
"spec/chingu/network_spec.rb",
|
202
203
|
"spec/chingu/parallax_spec.rb",
|
203
204
|
"spec/chingu/text_spec.rb",
|
204
205
|
"spec/chingu/window_spec.rb",
|
@@ -208,7 +209,7 @@ Gem::Specification.new do |s|
|
|
208
209
|
s.homepage = %q{http://github.com/ippa/chingu}
|
209
210
|
s.require_paths = ["lib"]
|
210
211
|
s.rubyforge_project = %q{chingu}
|
211
|
-
s.rubygems_version = %q{1.
|
212
|
+
s.rubygems_version = %q{1.5.2}
|
212
213
|
s.summary = %q{OpenGL accelerated 2D game framework for Ruby}
|
213
214
|
s.test_files = [
|
214
215
|
"examples/example10_traits_retrofy.rb",
|
@@ -257,6 +258,7 @@ Gem::Specification.new do |s|
|
|
257
258
|
"spec/chingu/helpers/options_setter_spec.rb",
|
258
259
|
"spec/chingu/inflector_spec.rb",
|
259
260
|
"spec/chingu/input_spec.rb",
|
261
|
+
"spec/chingu/network_spec.rb",
|
260
262
|
"spec/chingu/parallax_spec.rb",
|
261
263
|
"spec/chingu/text_spec.rb",
|
262
264
|
"spec/chingu/window_spec.rb",
|
@@ -264,18 +266,17 @@ Gem::Specification.new do |s|
|
|
264
266
|
]
|
265
267
|
|
266
268
|
if s.respond_to? :specification_version then
|
267
|
-
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
268
269
|
s.specification_version = 3
|
269
270
|
|
270
271
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
271
|
-
s.add_runtime_dependency(%q<gosu>, [">= 0.7.27"])
|
272
|
+
s.add_runtime_dependency(%q<gosu>, [">= 0.7.27.1"])
|
272
273
|
s.add_runtime_dependency(%q<rest-client>, [">= 0"])
|
273
274
|
s.add_runtime_dependency(%q<crack>, [">= 0"])
|
274
275
|
s.add_development_dependency(%q<rspec>, [">= 2.1.0"])
|
275
276
|
s.add_development_dependency(%q<watchr>, [">= 0"])
|
276
277
|
s.add_development_dependency(%q<rcov>, [">= 0"])
|
277
278
|
else
|
278
|
-
s.add_dependency(%q<gosu>, [">= 0.7.27"])
|
279
|
+
s.add_dependency(%q<gosu>, [">= 0.7.27.1"])
|
279
280
|
s.add_dependency(%q<rest-client>, [">= 0"])
|
280
281
|
s.add_dependency(%q<crack>, [">= 0"])
|
281
282
|
s.add_dependency(%q<rspec>, [">= 2.1.0"])
|
@@ -283,7 +284,7 @@ Gem::Specification.new do |s|
|
|
283
284
|
s.add_dependency(%q<rcov>, [">= 0"])
|
284
285
|
end
|
285
286
|
else
|
286
|
-
s.add_dependency(%q<gosu>, [">= 0.7.27"])
|
287
|
+
s.add_dependency(%q<gosu>, [">= 0.7.27.1"])
|
287
288
|
s.add_dependency(%q<rest-client>, [">= 0"])
|
288
289
|
s.add_dependency(%q<crack>, [">= 0"])
|
289
290
|
s.add_dependency(%q<rspec>, [">= 2.1.0"])
|
data/lib/chingu.rb
CHANGED
@@ -1,33 +1,24 @@
|
|
1
1
|
class Array
|
2
2
|
|
3
|
-
def each_collision(*
|
4
|
-
|
5
|
-
|
6
|
-
list.each_with_index { |nr, i| self[i..size].collect { |nr2| collide_pair << [nr,nr2] } }
|
7
|
-
collide_pair.each do |class1,class2|
|
8
|
-
class1.each_collision(class2) do |object1, object2|
|
3
|
+
def each_collision(*klasses)
|
4
|
+
self.each do |object1|
|
5
|
+
object1.each_collision(*klasses) do |object1, object2|
|
9
6
|
yield object1, object2
|
10
7
|
end
|
11
8
|
end
|
12
9
|
end
|
13
10
|
|
14
|
-
def each_bounding_circle_collision(*
|
15
|
-
|
16
|
-
|
17
|
-
list.each_with_index { |nr, i| self[i..size].collect { |nr2| collide_pair << [nr,nr2] } }
|
18
|
-
collide_pair.each do |class1,class2|
|
19
|
-
class1.each_bounding_circle_collision(class2) do |object1, object2|
|
11
|
+
def each_bounding_circle_collision(*klasses)
|
12
|
+
self.each do |object1|
|
13
|
+
object1.each_bounding_circle_collision(*klasses) do |object1, object2|
|
20
14
|
yield object1, object2
|
21
15
|
end
|
22
|
-
end
|
16
|
+
end
|
23
17
|
end
|
24
18
|
|
25
|
-
def each_bounding_box_collision(*
|
26
|
-
|
27
|
-
|
28
|
-
list.each_with_index { |nr, i| self[i..size].collect { |nr2| collide_pair << [nr,nr2] } }
|
29
|
-
collide_pair.each do |class1,class2|
|
30
|
-
class1.each_bounding_box_collision(class2) do |object1, object2|
|
19
|
+
def each_bounding_box_collision(*klasses)
|
20
|
+
self.each do |object1|
|
21
|
+
object1.each_bounding_box_collision(*klasses) do |object1, object2|
|
31
22
|
yield object1, object2
|
32
23
|
end
|
33
24
|
end
|
@@ -28,7 +28,7 @@ module Chingu
|
|
28
28
|
# Uses nonblocking polling TCP and YAML to communicate.
|
29
29
|
# If your game state inherits from NetworkClient you'll have the following methods available:
|
30
30
|
#
|
31
|
-
# connect(ip, port)
|
31
|
+
# connect(ip, port) # Start a blocking connection period. only connect() uses previosly given ip:port
|
32
32
|
# send_data(data) # Send raw data on the network, nonblocking
|
33
33
|
# send_msg(whatever ruby data) # Will get YAML'd and sent to server
|
34
34
|
# handle_incoming_data(max_size) # Nonblocking read of incoming server data
|
@@ -75,7 +75,9 @@ module Chingu
|
|
75
75
|
def initialize(options = {})
|
76
76
|
super
|
77
77
|
@timeout = options[:timeout] || 4
|
78
|
-
@debug =
|
78
|
+
@debug = options[:debug]
|
79
|
+
@ip = options[:ip] || "0.0.0.0"
|
80
|
+
@port = options[:port] || 7778
|
79
81
|
|
80
82
|
@socket = nil
|
81
83
|
@latency = 0
|
@@ -96,16 +98,18 @@ module Chingu
|
|
96
98
|
|
97
99
|
#
|
98
100
|
# Connect to a given ip:port (the server)
|
99
|
-
#
|
101
|
+
# Connect is done in a blocking manner.
|
102
|
+
# Will timeout after 4 seconds
|
100
103
|
#
|
101
|
-
def connect(ip, port =
|
104
|
+
def connect(ip = nil, port = nil)
|
102
105
|
return if @socket
|
103
|
-
|
104
|
-
@
|
106
|
+
|
107
|
+
@ip = ip if ip
|
108
|
+
@port = port if port
|
105
109
|
|
106
110
|
begin
|
107
111
|
status = Timeout::timeout(@timeout) do
|
108
|
-
@socket = TCPSocket.new(ip, port)
|
112
|
+
@socket = TCPSocket.new(@ip, @port)
|
109
113
|
@socket.setsockopt(Socket::IPPROTO_TCP,Socket::TCP_NODELAY,1)
|
110
114
|
on_connect
|
111
115
|
end
|
@@ -114,15 +118,21 @@ module Chingu
|
|
114
118
|
rescue Timeout
|
115
119
|
on_timeout
|
116
120
|
end
|
121
|
+
|
122
|
+
return self
|
117
123
|
end
|
118
124
|
|
125
|
+
#
|
126
|
+
# Called when connect() fails with connection refused (closed port)
|
127
|
+
#
|
119
128
|
def on_connection_refused
|
120
|
-
$window.caption = "Server: CONNECTION REFUSED"
|
121
129
|
connect(@ip, @port)
|
122
130
|
end
|
123
|
-
|
131
|
+
|
132
|
+
#
|
133
|
+
# Called when connect() recieves no initial answer from server
|
134
|
+
#
|
124
135
|
def on_timeout
|
125
|
-
$window.caption = "Server: CONNECTION TIMED OUT"
|
126
136
|
connect(@ip, @port)
|
127
137
|
end
|
128
138
|
|
@@ -130,14 +140,14 @@ module Chingu
|
|
130
140
|
# on_connect will be called when client successfully makes a connection to server
|
131
141
|
#
|
132
142
|
def on_connect
|
133
|
-
puts "[Connected to Server #{@ip}:#{@port}]"
|
143
|
+
puts "[Connected to Server #{@ip}:#{@port}]" if @debug
|
134
144
|
end
|
135
145
|
|
136
146
|
#
|
137
147
|
# on_disconnect will be called when server disconnects client for whatever reason
|
138
148
|
#
|
139
149
|
def on_disconnect
|
140
|
-
puts "[Disconnected from Server]"
|
150
|
+
puts "[Disconnected from Server]" if @debug
|
141
151
|
end
|
142
152
|
|
143
153
|
#
|
@@ -199,6 +209,8 @@ module Chingu
|
|
199
209
|
def disconnect_from_server
|
200
210
|
@socket.close
|
201
211
|
end
|
212
|
+
alias close disconnect_from_server
|
213
|
+
alias stop disconnect_from_server
|
202
214
|
|
203
215
|
end
|
204
216
|
end
|
@@ -47,11 +47,7 @@ module Chingu
|
|
47
47
|
#
|
48
48
|
# Usage:
|
49
49
|
# ServerState < Chingu::GameStates::NetworkServer
|
50
|
-
#
|
51
|
-
# super # this is always needed!
|
52
|
-
# connect_to_server(options[:ip], options[:port])
|
53
|
-
# end
|
54
|
-
#
|
50
|
+
# # incoming client/connection...
|
55
51
|
# def on_connect(socket)
|
56
52
|
# send_msg(:cmd => :ping, :timestamp => Gosu::milliseconds)
|
57
53
|
# end
|
@@ -64,7 +60,7 @@ module Chingu
|
|
64
60
|
# end
|
65
61
|
# end
|
66
62
|
#
|
67
|
-
# push_game_state ServerState.new(:ip => "127.0.0.1", :port => 7778)
|
63
|
+
# push_game_state ServerState.new(:ip => "127.0.0.1", :port => 7778).start
|
68
64
|
#
|
69
65
|
# NetworkServer works mostly like NetworkClient with a few differences
|
70
66
|
# - since a server handles many sockets (1 for each connected client) all callbacks first argument is 'socket'
|
@@ -78,7 +74,9 @@ module Chingu
|
|
78
74
|
def initialize(options = {})
|
79
75
|
super
|
80
76
|
|
81
|
-
@
|
77
|
+
@ip = options[:ip] || "0.0.0.0"
|
78
|
+
@port = options[:port] || 7778
|
79
|
+
@debug = options[:debug]
|
82
80
|
@socket = nil
|
83
81
|
@sockets = []
|
84
82
|
@buffered_output = YAML::Stream.new
|
@@ -88,20 +86,20 @@ module Chingu
|
|
88
86
|
end
|
89
87
|
|
90
88
|
#
|
91
|
-
# Start server
|
89
|
+
# Start server
|
92
90
|
#
|
93
|
-
def start(ip
|
94
|
-
@ip = ip
|
95
|
-
@port = port
|
96
|
-
|
91
|
+
def start(ip=nil, port=nil)
|
92
|
+
@ip = ip if ip
|
93
|
+
@port = port if port
|
97
94
|
begin
|
98
|
-
@socket = TCPServer.new(ip, port)
|
95
|
+
@socket = TCPServer.new(@ip, @port)
|
99
96
|
@socket.setsockopt(Socket::IPPROTO_TCP,Socket::TCP_NODELAY,1)
|
100
97
|
on_start
|
101
|
-
|
102
98
|
rescue
|
103
99
|
on_start_error($!)
|
104
100
|
end
|
101
|
+
|
102
|
+
return self
|
105
103
|
end
|
106
104
|
|
107
105
|
#
|
@@ -251,11 +249,13 @@ module Chingu
|
|
251
249
|
# Stops server
|
252
250
|
#
|
253
251
|
def stop
|
252
|
+
return unless @socket
|
254
253
|
begin
|
255
254
|
@socket.close
|
256
255
|
rescue Errno::ENOTCONN
|
257
256
|
end
|
258
257
|
end
|
258
|
+
alias close stop
|
259
259
|
|
260
260
|
end
|
261
261
|
end
|
data/lib/chingu/simple_menu.rb
CHANGED
@@ -37,12 +37,12 @@ module Chingu
|
|
37
37
|
# @font_size = options.delete(:font_size) || 30
|
38
38
|
@menu_items = options.delete(:menu_items)
|
39
39
|
@x = options.delete(:x) || $window.width/2
|
40
|
-
@y = options.delete(:y) ||
|
40
|
+
@y = options.delete(:y) || 0
|
41
41
|
@spacing = options.delete(:spacing) || 100
|
42
42
|
@items = []
|
43
43
|
@visible = true
|
44
44
|
|
45
|
-
y = @
|
45
|
+
y = @y
|
46
46
|
menu_items.each do |key, value|
|
47
47
|
item = if key.is_a? String
|
48
48
|
Text.new(key, options.dup)
|
@@ -57,7 +57,7 @@ module Chingu
|
|
57
57
|
item.options[:on_deselect] = method(:on_deselect)
|
58
58
|
item.options[:action] = value
|
59
59
|
|
60
|
-
item.rotation_center = :
|
60
|
+
item.rotation_center = :center_top
|
61
61
|
item.x = @x
|
62
62
|
item.y = y
|
63
63
|
y += item.height + @spacing
|
@@ -0,0 +1,78 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
module Chingu
|
4
|
+
describe "Network" do
|
5
|
+
|
6
|
+
describe "Network Server" do
|
7
|
+
|
8
|
+
it "should open listening port on start()" do
|
9
|
+
@server = Chingu::GameStates::NetworkServer.new(:ip => "0.0.0.0", :port => 9999)
|
10
|
+
@server.should_receive(:on_start)
|
11
|
+
@server.start
|
12
|
+
@server.stop
|
13
|
+
end
|
14
|
+
|
15
|
+
it "should call on_start_error() if failing" do
|
16
|
+
@server = Chingu::GameStates::NetworkServer.new(:ip => "1.2.3.999", :port => 12345678) # crazy ip:port
|
17
|
+
@server.should_receive(:on_start_error)
|
18
|
+
@server.start
|
19
|
+
@server.stop
|
20
|
+
end
|
21
|
+
|
22
|
+
it "should call on_connect() and on_disconnect() when client connects" do
|
23
|
+
@server = Chingu::GameStates::NetworkServer.new(:ip => "0.0.0.0", :port => 9999)
|
24
|
+
@client = Chingu::GameStates::NetworkClient.new(:ip => "127.0.0.1", :port => 9999)
|
25
|
+
|
26
|
+
@server.should_receive(:on_start)
|
27
|
+
@server.should_receive(:on_connect).with(anything()) # anything() == a socket
|
28
|
+
@client.should_receive(:on_connect)
|
29
|
+
@server.start
|
30
|
+
@client.connect
|
31
|
+
@server.update
|
32
|
+
|
33
|
+
@client.stop
|
34
|
+
@server.stop
|
35
|
+
end
|
36
|
+
|
37
|
+
end
|
38
|
+
|
39
|
+
describe "Network Client" do
|
40
|
+
it "should call on_connection_refused callback when connecting to closed port" do
|
41
|
+
@client = Chingu::GameStates::NetworkClient.new(:ip => "127.0.0.1", :port => 55421) # closed we assume
|
42
|
+
@client.should_receive(:on_connection_refused)
|
43
|
+
@client.connect
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
describe "Network communication" do
|
48
|
+
before do
|
49
|
+
@server = Chingu::GameStates::NetworkServer.new(:ip => "0.0.0.0", :port => 9999).start
|
50
|
+
@client = Chingu::GameStates::NetworkClient.new(:ip => "127.0.0.1", :port => 9999).connect
|
51
|
+
end
|
52
|
+
|
53
|
+
after do
|
54
|
+
@server.close
|
55
|
+
@client.close
|
56
|
+
end
|
57
|
+
|
58
|
+
it "should send/recv strings" do
|
59
|
+
@server.should_receive(:on_msg).with(anything(), "woff!")
|
60
|
+
@client.send_msg("woff!")
|
61
|
+
@server.update
|
62
|
+
end
|
63
|
+
|
64
|
+
it "should send/recv hashes" do
|
65
|
+
@server.should_receive(:on_msg).with(anything(), {:foo => :bar})
|
66
|
+
@client.send_msg({:foo => :bar})
|
67
|
+
@server.update
|
68
|
+
end
|
69
|
+
|
70
|
+
it "should send/recv arrays" do
|
71
|
+
@server.should_receive(:on_msg).with(anything(), [1,2,3])
|
72
|
+
@client.send_msg([1,2,3])
|
73
|
+
@server.update
|
74
|
+
end
|
75
|
+
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
metadata
CHANGED
@@ -1,113 +1,94 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: chingu
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
|
6
|
-
- 0
|
7
|
-
- 9rc1
|
8
|
-
version: 0.9rc1
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.9rc2
|
5
|
+
prerelease: 3
|
9
6
|
platform: ruby
|
10
|
-
authors:
|
7
|
+
authors:
|
11
8
|
- ippa
|
12
9
|
autorequire:
|
13
10
|
bindir: bin
|
14
11
|
cert_chain: []
|
15
|
-
|
16
|
-
date: 2011-02-20 00:00:00 +01:00
|
12
|
+
date: 2011-02-26 00:00:00.000000000 +01:00
|
17
13
|
default_executable:
|
18
|
-
dependencies:
|
19
|
-
- !ruby/object:Gem::Dependency
|
14
|
+
dependencies:
|
15
|
+
- !ruby/object:Gem::Dependency
|
20
16
|
name: gosu
|
21
|
-
|
22
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
17
|
+
requirement: &24735936 !ruby/object:Gem::Requirement
|
23
18
|
none: false
|
24
|
-
requirements:
|
25
|
-
- -
|
26
|
-
- !ruby/object:Gem::Version
|
27
|
-
|
28
|
-
- 0
|
29
|
-
- 7
|
30
|
-
- 27
|
31
|
-
version: 0.7.27
|
19
|
+
requirements:
|
20
|
+
- - ! '>='
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: 0.7.27.1
|
32
23
|
type: :runtime
|
33
|
-
version_requirements: *id001
|
34
|
-
- !ruby/object:Gem::Dependency
|
35
|
-
name: rest-client
|
36
24
|
prerelease: false
|
37
|
-
|
25
|
+
version_requirements: *24735936
|
26
|
+
- !ruby/object:Gem::Dependency
|
27
|
+
name: rest-client
|
28
|
+
requirement: &24735504 !ruby/object:Gem::Requirement
|
38
29
|
none: false
|
39
|
-
requirements:
|
40
|
-
- -
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
|
43
|
-
- 0
|
44
|
-
version: "0"
|
30
|
+
requirements:
|
31
|
+
- - ! '>='
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
45
34
|
type: :runtime
|
46
|
-
version_requirements: *id002
|
47
|
-
- !ruby/object:Gem::Dependency
|
48
|
-
name: crack
|
49
35
|
prerelease: false
|
50
|
-
|
36
|
+
version_requirements: *24735504
|
37
|
+
- !ruby/object:Gem::Dependency
|
38
|
+
name: crack
|
39
|
+
requirement: &24735072 !ruby/object:Gem::Requirement
|
51
40
|
none: false
|
52
|
-
requirements:
|
53
|
-
- -
|
54
|
-
- !ruby/object:Gem::Version
|
55
|
-
|
56
|
-
- 0
|
57
|
-
version: "0"
|
41
|
+
requirements:
|
42
|
+
- - ! '>='
|
43
|
+
- !ruby/object:Gem::Version
|
44
|
+
version: '0'
|
58
45
|
type: :runtime
|
59
|
-
version_requirements: *id003
|
60
|
-
- !ruby/object:Gem::Dependency
|
61
|
-
name: rspec
|
62
46
|
prerelease: false
|
63
|
-
|
47
|
+
version_requirements: *24735072
|
48
|
+
- !ruby/object:Gem::Dependency
|
49
|
+
name: rspec
|
50
|
+
requirement: &24734628 !ruby/object:Gem::Requirement
|
64
51
|
none: false
|
65
|
-
requirements:
|
66
|
-
- -
|
67
|
-
- !ruby/object:Gem::Version
|
68
|
-
segments:
|
69
|
-
- 2
|
70
|
-
- 1
|
71
|
-
- 0
|
52
|
+
requirements:
|
53
|
+
- - ! '>='
|
54
|
+
- !ruby/object:Gem::Version
|
72
55
|
version: 2.1.0
|
73
56
|
type: :development
|
74
|
-
version_requirements: *id004
|
75
|
-
- !ruby/object:Gem::Dependency
|
76
|
-
name: watchr
|
77
57
|
prerelease: false
|
78
|
-
|
58
|
+
version_requirements: *24734628
|
59
|
+
- !ruby/object:Gem::Dependency
|
60
|
+
name: watchr
|
61
|
+
requirement: &24734268 !ruby/object:Gem::Requirement
|
79
62
|
none: false
|
80
|
-
requirements:
|
81
|
-
- -
|
82
|
-
- !ruby/object:Gem::Version
|
83
|
-
|
84
|
-
- 0
|
85
|
-
version: "0"
|
63
|
+
requirements:
|
64
|
+
- - ! '>='
|
65
|
+
- !ruby/object:Gem::Version
|
66
|
+
version: '0'
|
86
67
|
type: :development
|
87
|
-
version_requirements: *id005
|
88
|
-
- !ruby/object:Gem::Dependency
|
89
|
-
name: rcov
|
90
68
|
prerelease: false
|
91
|
-
|
69
|
+
version_requirements: *24734268
|
70
|
+
- !ruby/object:Gem::Dependency
|
71
|
+
name: rcov
|
72
|
+
requirement: &24733848 !ruby/object:Gem::Requirement
|
92
73
|
none: false
|
93
|
-
requirements:
|
94
|
-
- -
|
95
|
-
- !ruby/object:Gem::Version
|
96
|
-
|
97
|
-
- 0
|
98
|
-
version: "0"
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: '0'
|
99
78
|
type: :development
|
100
|
-
|
101
|
-
|
79
|
+
prerelease: false
|
80
|
+
version_requirements: *24733848
|
81
|
+
description: OpenGL accelerated 2D game framework for Ruby. Builds on Gosu (Ruby/C++)
|
82
|
+
which provides all the core functionality. Chingu adds simple yet powerful game
|
83
|
+
states, prettier input handling, deployment safe asset-handling, a basic re-usable
|
84
|
+
game object and stackable game logic.
|
102
85
|
email: ippa@rubylicio.us
|
103
86
|
executables: []
|
104
|
-
|
105
87
|
extensions: []
|
106
|
-
|
107
|
-
extra_rdoc_files:
|
88
|
+
extra_rdoc_files:
|
108
89
|
- LICENSE
|
109
90
|
- README.rdoc
|
110
|
-
files:
|
91
|
+
files:
|
111
92
|
- .rspec
|
112
93
|
- History.txt
|
113
94
|
- LICENSE
|
@@ -290,6 +271,7 @@ files:
|
|
290
271
|
- spec/chingu/images/rect_20x20.png
|
291
272
|
- spec/chingu/inflector_spec.rb
|
292
273
|
- spec/chingu/input_spec.rb
|
274
|
+
- spec/chingu/network_spec.rb
|
293
275
|
- spec/chingu/parallax_spec.rb
|
294
276
|
- spec/chingu/text_spec.rb
|
295
277
|
- spec/chingu/window_spec.rb
|
@@ -298,38 +280,29 @@ files:
|
|
298
280
|
has_rdoc: true
|
299
281
|
homepage: http://github.com/ippa/chingu
|
300
282
|
licenses: []
|
301
|
-
|
302
283
|
post_install_message:
|
303
284
|
rdoc_options: []
|
304
|
-
|
305
|
-
require_paths:
|
285
|
+
require_paths:
|
306
286
|
- lib
|
307
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
287
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
308
288
|
none: false
|
309
|
-
requirements:
|
310
|
-
- -
|
311
|
-
- !ruby/object:Gem::Version
|
312
|
-
|
313
|
-
|
314
|
-
version: "0"
|
315
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
289
|
+
requirements:
|
290
|
+
- - ! '>='
|
291
|
+
- !ruby/object:Gem::Version
|
292
|
+
version: '0'
|
293
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
316
294
|
none: false
|
317
|
-
requirements:
|
318
|
-
- -
|
319
|
-
- !ruby/object:Gem::Version
|
320
|
-
segments:
|
321
|
-
- 1
|
322
|
-
- 3
|
323
|
-
- 1
|
295
|
+
requirements:
|
296
|
+
- - ! '>'
|
297
|
+
- !ruby/object:Gem::Version
|
324
298
|
version: 1.3.1
|
325
299
|
requirements: []
|
326
|
-
|
327
300
|
rubyforge_project: chingu
|
328
|
-
rubygems_version: 1.
|
301
|
+
rubygems_version: 1.5.2
|
329
302
|
signing_key:
|
330
303
|
specification_version: 3
|
331
304
|
summary: OpenGL accelerated 2D game framework for Ruby
|
332
|
-
test_files:
|
305
|
+
test_files:
|
333
306
|
- examples/example10_traits_retrofy.rb
|
334
307
|
- examples/example11_animation.rb
|
335
308
|
- examples/example12_trait_timer.rb
|
@@ -376,6 +349,7 @@ test_files:
|
|
376
349
|
- spec/chingu/helpers/options_setter_spec.rb
|
377
350
|
- spec/chingu/inflector_spec.rb
|
378
351
|
- spec/chingu/input_spec.rb
|
352
|
+
- spec/chingu/network_spec.rb
|
379
353
|
- spec/chingu/parallax_spec.rb
|
380
354
|
- spec/chingu/text_spec.rb
|
381
355
|
- spec/chingu/window_spec.rb
|