chingu 0.6.6 → 0.6.7
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.
- data/chingu.gemspec +2 -2
- data/lib/chingu.rb +1 -1
- data/lib/chingu/traits/timer.rb +16 -8
- metadata +6 -27
- data.tar.gz.sig +0 -3
- metadata.gz.sig +0 -0
data/chingu.gemspec
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{chingu}
|
5
|
-
s.version = "0.6.
|
5
|
+
s.version = "0.6.7"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["ippa"]
|
9
|
-
s.date = %q{2009-12-
|
9
|
+
s.date = %q{2009-12-13}
|
10
10
|
s.description = %q{OpenGL accelerated 2D game framework for Ruby.
|
11
11
|
Builds on the awesome Gosu (Ruby/C++) which provides all the core functionality.
|
12
12
|
It adds simple yet powerful game states, prettier input handling, deployment safe asset-handling, a basic re-usable game object and automation of common task.}
|
data/lib/chingu.rb
CHANGED
data/lib/chingu/traits/timer.rb
CHANGED
@@ -47,8 +47,10 @@ module Chingu
|
|
47
47
|
# Executes block each update during 'time' milliseconds
|
48
48
|
#
|
49
49
|
def during(time, options = {}, &block)
|
50
|
-
|
51
|
-
|
50
|
+
if options[:name]
|
51
|
+
return if timer_exists?(options[:name]) && options[:preserve]
|
52
|
+
stop_timer(options[:name])
|
53
|
+
end
|
52
54
|
|
53
55
|
ms = Gosu::milliseconds()
|
54
56
|
@_last_timer = [options[:name], ms, ms + time, block]
|
@@ -60,8 +62,10 @@ module Chingu
|
|
60
62
|
# Executes block after 'time' milliseconds
|
61
63
|
#
|
62
64
|
def after(time, options = {}, &block)
|
63
|
-
|
64
|
-
|
65
|
+
if options[:name]
|
66
|
+
return if timer_exists?(options[:name]) && options[:preserve]
|
67
|
+
stop_timer(options[:name])
|
68
|
+
end
|
65
69
|
|
66
70
|
ms = Gosu::milliseconds()
|
67
71
|
@_last_timer = [options[:name], ms + time, nil, block]
|
@@ -73,8 +77,10 @@ module Chingu
|
|
73
77
|
# Executes block each update during 'start_time' and 'end_time'
|
74
78
|
#
|
75
79
|
def between(start_time, end_time, options = {}, &block)
|
76
|
-
|
77
|
-
|
80
|
+
if options[:name]
|
81
|
+
return if timer_exists?(options[:name]) && options[:preserve]
|
82
|
+
stop_timer(options[:name])
|
83
|
+
end
|
78
84
|
|
79
85
|
ms = Gosu::milliseconds()
|
80
86
|
@_last_timer = [options[:name], ms + start_time, ms + end_time, block]
|
@@ -86,8 +92,10 @@ module Chingu
|
|
86
92
|
# Executes block every 'delay' milliseconds
|
87
93
|
#
|
88
94
|
def every(delay, options = {}, &block)
|
89
|
-
|
90
|
-
|
95
|
+
if options[:name]
|
96
|
+
return if timer_exists?(options[:name]) && options[:preserve]
|
97
|
+
stop_timer(options[:name])
|
98
|
+
end
|
91
99
|
|
92
100
|
ms = Gosu::milliseconds()
|
93
101
|
@_repeating_timers << [options[:name], ms + delay, delay, block]
|
metadata
CHANGED
@@ -1,36 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chingu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ippa
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
|
-
cert_chain:
|
11
|
-
- |
|
12
|
-
-----BEGIN CERTIFICATE-----
|
13
|
-
MIIDMDCCAhigAwIBAgIBADANBgkqhkiG9w0BAQUFADA+MQ0wCwYDVQQDDARpcHBh
|
14
|
-
MRkwFwYKCZImiZPyLGQBGRYJcnVieWxpY2lvMRIwEAYKCZImiZPyLGQBGRYCdXMw
|
15
|
-
HhcNMDkwODA2MDEwMDEyWhcNMTAwODA2MDEwMDEyWjA+MQ0wCwYDVQQDDARpcHBh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
|
10
|
+
cert_chain: []
|
32
11
|
|
33
|
-
date: 2009-12-
|
12
|
+
date: 2009-12-13 00:00:00 +01:00
|
34
13
|
default_executable:
|
35
14
|
dependencies:
|
36
15
|
- !ruby/object:Gem::Dependency
|
@@ -44,8 +23,8 @@ dependencies:
|
|
44
23
|
version: 2.4.0
|
45
24
|
version:
|
46
25
|
description: |-
|
47
|
-
OpenGL accelerated 2D game framework for Ruby.
|
48
|
-
Builds on the awesome Gosu (Ruby/C++) which provides all the core functionality.
|
26
|
+
OpenGL accelerated 2D game framework for Ruby.
|
27
|
+
Builds on the awesome Gosu (Ruby/C++) which provides all the core functionality.
|
49
28
|
It adds simple yet powerful game states, prettier input handling, deployment safe asset-handling, a basic re-usable game object and automation of common task.
|
50
29
|
email:
|
51
30
|
- ippa@rubylicio.us
|
@@ -161,7 +140,7 @@ files:
|
|
161
140
|
- lib/chingu/traits/velocity.rb
|
162
141
|
- lib/chingu/window.rb
|
163
142
|
has_rdoc: true
|
164
|
-
homepage: http://github.com/ippa/chingu/tree/master
|
143
|
+
homepage: http://github.com/ippa/chingu/tree/master
|
165
144
|
licenses: []
|
166
145
|
|
167
146
|
post_install_message:
|
data.tar.gz.sig
DELETED
metadata.gz.sig
DELETED
Binary file
|