Browse Source

[cpp] Closes #1149, C++ EventTimeline had a bug that prevented it from firing events.

badlogic 7 years ago
parent
commit
5087cd0373

+ 0 - 4
spine-cpp/spine-cpp/src/spine/EventTimeline.cpp

@@ -61,10 +61,6 @@ void EventTimeline::apply(Skeleton &skeleton, float lastTime, float time, Vector
 
 	Vector<Event *> &events = *pEvents;
 
-	if (events.size() == 0) {
-		return;
-	}
-
 	size_t frameCount = _frames.size();
 
 	if (lastTime > time) {

+ 1 - 1
spine-sfml/cpp/example/main.cpp

@@ -449,9 +449,9 @@ int main () {
 	DebugExtension dbgExtension;
 	SpineExtension::setInstance(&dbgExtension);
 
+	testcase(spineboy, "data/spineboy-ess.json", "data/spineboy-ess.skel", "data/spineboy.atlas", 0.6f);
 	testcase(raptor, "data/raptor-pro.json", "data/raptor-pro.skel", "data/raptor.atlas", 0.5f);
 	testcase(test, "data/tank-pro.json", "data/tank-pro.skel", "data/tank.atlas", 1.0f);
-	testcase(spineboy, "data/spineboy-ess.json", "data/spineboy-ess.skel", "data/spineboy.atlas", 0.6f);
 	testcase(owl, "data/owl-pro.json", "data/owl-pro.skel", "data/owl.atlas", 0.5f);
 	testcase(coin, "data/coin-pro.json", "data/coin-pro.skel", "data/coin.atlas", 0.5f);
 	testcase(vine, "data/vine-pro.json", "data/vine-pro.skel", "data/vine.atlas", 0.5f);