<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>cocos2d for iPhone &#187; Topic: touch dispatcher for dummies?</title>
		<link>http://www.cocos2d-iphone.org/forum/topic/1420</link>
		<description>A fast, easy to use, free, and community supported 2D game engine</description>
		<language>en-US</language>
		<pubDate>Fri, 10 Feb 2012 02:00:45 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.cocos2d-iphone.org/forum/search.php</link>
		</textInput>
		<atom:link href="http://www.cocos2d-iphone.org/forum/rss/topic/1420" rel="self" type="application/rss+xml" />

		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9679</link>
			<pubDate>Thu, 27 Aug 2009 13:36:59 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9679@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Congratulations, I admire your perseverance.  Hopefully things will get easier.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9678</link>
			<pubDate>Thu, 27 Aug 2009 13:32:41 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9678@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>OK I got rid of that and also the<br />
<pre><code>- (void)ccTouchEnded:(UITouch *)touch withEvent:(UIEvent *)event
{
	NSAssert(state == kPaddleStateGrabbed, @&#34;Paddle - Unexpected state!&#34;);	

	state = kPaddleStateUngrabbed;

}</code></pre>
<p>which was at the end and was causing the crash.</p>
<p>Thank you so much - no more dumb questions - at least for today wink-wink!
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9674</link>
			<pubDate>Thu, 27 Aug 2009 13:17:24 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9674@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Get rid of that "return kEventHandled" and make sure state is not being set anywhere else.  If it crashes then where and why?  What is printed in the console?
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9671</link>
			<pubDate>Thu, 27 Aug 2009 12:51:30 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9671@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>OK I had a look before in the day but this is what I've added now:</p>
<pre><code>- (BOOL)ccTouchBegan:(UITouch *)touch withEvent:(UIEvent *)event
{

	if (state != kPaddleStateUngrabbed) return NO;
	if ( ![self containsTouchLocation:touch] ) return NO;

	state = kPaddleStateGrabbed; 

	id actionBy = [ScaleBy actionWithDuration: 1.0f scale: 2.0f];
	id actionByBack = [actionBy reverse];
	id actionCallFunc = [CallFunc actionWithTarget:self selector:@selector(kPaddleStateUngrabbed)];

	id actionSequence = [Sequence actions: actionBy, actionByBack, actionCallFunc, nil];
	[self runAction: actionSequence];	

	return kEventHandled;
	return YES;
}
	-(void)kPaddleStateUngrabbed
	{
		NSAssert(state == kPaddleStateGrabbed, @&#34;Paddle - Unexpected state!&#34;);
		state = kPaddleStateUngrabbed;
	}</code></pre>
<p>It builds OK but the paddle doesn't seem to revert to its initial state and many consecutive touches just makes it crash.<br />
:-(
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9668</link>
			<pubDate>Thu, 27 Aug 2009 12:30:59 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9668@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>^ Did you look in the Wiki, it seems pretty clear to me.  Just use the first model and change the state to kPaddleStateUngrabbed in the  doATask method.  Don't forget to comment out that state change in ccTouchEnded if you still have it too.</p>
<p><a href="http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:actions_special" rel="nofollow">http://www.cocos2d-iphone.org/wiki/doku.php/prog_guide:actions_special</a>
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9667</link>
			<pubDate>Thu, 27 Aug 2009 12:24:18 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9667@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I'm embarrassed to say this but the more I look at the SpritesTest example with CallFunc the less I understand. I am truly losing my mind here. I've tried so many different versions of my action with CallFunc. I would really need to see another working example of CallFunc... SOS
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9649</link>
			<pubDate>Thu, 27 Aug 2009 07:18:18 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9649@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Do you still have this code from TouchesTest?</p>
<pre><code>- (void)ccTouchEnded:(UITouch *)touch withEvent:(UIEvent *)event
{
	NSAssert(state == kPaddleStateGrabbed, @&#34;Paddle - Unexpected state!&#34;);	

	state = kPaddleStateUngrabbed;
}</code></pre>
<p>See how the state is used as a guard in ccTouchBegan but when the touch ended the state is changed back to allow the touch began code to run again?  What you need to do is only change the state back to kPaddleStateUngrabbed when your action ends and unfortunately the best way to do that is with a callFunc to a method that sets state = kPaddleStateUngrabbed.  So jump back on the callFunc horse and post your code if it doesn't work.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9647</link>
			<pubDate>Thu, 27 Aug 2009 07:06:42 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9647@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I'm just messing around with the TouchesTest demo and the states. What I want to do is have the paddle return to its original state and location after the touch is ended (finger taken off the screen) Right now each touch causes the paddle to be scaled but double tapping just reinitiates it even if it is in the middle of the scaling action.</p>
<pre><code>- (BOOL)ccTouchBegan:(UITouch *)touch withEvent:(UIEvent *)event
{

	if (state != kPaddleStateUngrabbed) return NO;
	if ( ![self containsTouchLocation:touch] ) return NO;

	state = kPaddleStateGrabbed; 

	id actionBy = [ScaleBy actionWithDuration: 1.0f scale: 2.0f];
	id actionByBack = [actionBy reverse];
	;
	[self runAction: [Sequence actions:actionBy, actionByBack, nil]];

	return kEventHandled;
	return YES;
}</code></pre>
<p>As you can see from the demo there isn't much that I have done except add the action - I just don't know how to limit this action.<br />
Also, I gave up on callFunc :-(
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9645</link>
			<pubDate>Thu, 27 Aug 2009 06:54:12 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9645@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Is it making sense now?  Did you get your callFunc working?  It may be easier if you post your code.</p>
<p>Unfortunately I don't know php so I can't explain things in those terms.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9644</link>
			<pubDate>Thu, 27 Aug 2009 06:33:09 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9644@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Thanks, mate.<br />
I'm just learning Objective C. I work in education and work with people and the only limited IT experience I have is in mysql and php :-(<br />
Cocos2d/iphone is just a hobby for me now.
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9638</link>
			<pubDate>Thu, 27 Aug 2009 05:07:29 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9638@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>You are on the right track but I think most people would just code TouchEnded as a simple BOOL rather than a function.  If it was a function you'd need [self TouchEnded] or a property would be self.TouchEnded.</p>
<p>What programming language(s) do you have experience in, it seems like you are struggling with basic programming concepts that have nothing to do with cocos2d or even Objective C.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9538</link>
			<pubDate>Wed, 26 Aug 2009 16:00:21 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9538@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Can someone tell me if Im thinking in the right direction</p>
<p>if I add the following statement:</p>
<pre><code>if (TouchEnded == NO)
		return NO;</code></pre>
<p>it should not initiate the a new touch until the action has completed?<br />
But how do I declare this function for the first time?</p>
<p>PS I know my questions are really simple but I just don't know.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9536</link>
			<pubDate>Wed, 26 Aug 2009 15:04:30 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9536@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>anyone, pls :---(
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420/page/2#post-9512</link>
			<pubDate>Wed, 26 Aug 2009 08:26:21 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9512@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I'm still having trouble implementing this callback method in my sequence - Maybe someone can help me with an if statement not allowing another action to be initiated during the first running action - I really need someone to walk me through this ;-)
</p></description>
		</item>
		<item>
			<title>jbhewitt on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9477</link>
			<pubDate>Wed, 26 Aug 2009 00:06:22 +0000</pubDate>
			<dc:creator>jbhewitt</dc:creator>
			<guid isPermaLink="false">9477@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Thank you so much cjl for your informative explanation! </p>
<p>I learnt a lot in regards to the rect method, as it now makes sense what it is doing when you draw a rectangle relative to the zero point in the centre.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9383</link>
			<pubDate>Tue, 25 Aug 2009 16:36:37 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9383@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>My game consists of sprites that have to be pushed... I call them buttons just for reference sake.
</p></description>
		</item>
		<item>
			<title>cjl on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9381</link>
			<pubDate>Tue, 25 Aug 2009 16:30:19 +0000</pubDate>
			<dc:creator>cjl</dc:creator>
			<guid isPermaLink="false">9381@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/774'>Alex</a>:</p>
<p>When you issue a return statement, the remainder of the function is not evaluated. If you put 'return YES' where you have 'return kEventHandled', it will work.</p>
<p>The rect method above will work for your sprite, too, assuming your sprite 'goes all the way to the edges' in your png (doesn't have any padding around it, which it shouldn't). Read what I wrote above again. The rect method produces a rect relative to the node (sprite) coordinate system.</p>
<p>By the way, I'm not quite sure why you're making a button, because Cocos already provides Menu and MenuItem.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9371</link>
			<pubDate>Tue, 25 Aug 2009 15:34:05 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9371@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/49'>cjl</a> - wow thanks for the lengthy explanation- I'm still digesting. I have a few comments though:</p>
<p>'- (BOOL)ccTouchBegan:(UITouch *)touch withEvent:(UIEvent *)event<br />
{  </p>
<p>	if (state != kPaddleStateUngrabbed) return NO;<br />
	if ( ![self containsTouchLocation:touch] ) return NO;</p>
<p>	state = kPaddleStateGrabbed;<br />
	//return YES;</p>
<p>	id actionBy = [ScaleBy actionWithDuration: 1.0f scale: 2.0f];<br />
	id actionByBack = [actionBy reverse];</p>
<p>	[self runAction: [Sequence actions:actionBy, actionByBack, nil]];</p>
<p>	return kEventHandled;<br />
}'</p>
<p>I can only get my action  to work if 'return YES' is erased after 'state =  kPaddleStateGrabbed; '<br />
Anyone have a clue why?</p>
<p>Also, to understand the CGRect method correctly in terms of a sprite with a  non-movable location of x=200 and y=160 and width of 45 and height of 100 - how would we implement it - I am trying to produce a button and the paddles in the example are a little to advanced for a newbie like me ;)</p>
<p>@<a href='http://www.cocos2d-iphone.org/forum/profile/131'>Steve</a> Oldmeadow<br />
I had a look at the sprites test which contains the CallFunc action.<br />
I tried to add it to my sequence as the final action as:<br />
'[CallFunc actionWithTarget:self selector:@selector(callback1)],'<br />
And the sequence can not be started?<br />
This seems like the easiest way to implement this method - but I can't seem to get it to work?
</p></description>
		</item>
		<item>
			<title>cjl on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9365</link>
			<pubDate>Tue, 25 Aug 2009 14:42:04 +0000</pubDate>
			<dc:creator>cjl</dc:creator>
			<guid isPermaLink="false">9365@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>OK - rather than confuse things with my crummy code, let's take a look at the TouchesTest code distributed with Cocos2D.</p>
<p>Most of the interesting code is in the Paddle class. Let's look at the interface in 'Paddle.h':</p>
<pre><code>@interface Paddle : TextureNode &#60;TargetedTouchDelegate&#62; {</code></pre>
<p>So, Paddle is a subclass of TextureNode. Notice the code in angle brackets? We are declaring that our Paddle class will adhere to the TargetedTouchDelegate protocol. This is like signing a contract, and promising to implement the methods that this protocol expects to exist. If we look at the definition of the TargetedTouchDelegate protocol in 'TouchDelegateProtocol', we see:</p>
<pre><code>@protocol TargetedTouchDelegate &#60;NSObject&#62;

/** Return YES to claim the touch.
 @since v0.8
 */
- (BOOL)ccTouchBegan:(UITouch *)touch withEvent:(UIEvent *)event;
@optional
// touch updates:
- (void)ccTouchMoved:(UITouch *)touch withEvent:(UIEvent *)event;
- (void)ccTouchEnded:(UITouch *)touch withEvent:(UIEvent *)event;
- (void)ccTouchCancelled:(UITouch *)touch withEvent:(UIEvent *)event;
@end</code></pre>
<p>Reading this, we can see that we must implement the 'ccTouchesBegan' method. Also, we may implement 'ccTouchesMoved', 'ccTouchesEnded', and 'ccTouchesCanceled', but the protocol does not require it. In practice, you will almost always implement the optional methods.</p>
<p>Why are we adhering to the 'TargetedTouchDelegate' protocol? Because the touch dispatcher expects us to. When the user touches the screen, the touch dispatcher will call the appropriate method on our Paddle class. Obviously, the method that the touch dispatcher calls must exist, but we are promising that it exists when we declare that our class adheres to the 'TargetedTouchDelegate' protocol.</p>
<p>OK, so far so good. Back to the paddle class implementation, where we define the methods we promised to in our protocol declaration.</p>
<p>First, in the 'onEnter' method, we tell the touch dispatcher that Paddle is a delegate:</p>
<pre><code>- (void)onEnter
{
        [[TouchDispatcher sharedDispatcher] addTargetedDelegate:self priority:0 swallowsTouches:YES];
        [super onEnter];
}</code></pre>
<p>Then, we implement the required method:</p>
<pre><code>- (BOOL)ccTouchBegan:(UITouch *)touch withEvent:(UIEvent *)event
{
        if (state != kPaddleStateUngrabbed) return NO;
        if ( ![self containsTouchLocation:touch] ) return NO;

        state = kPaddleStateGrabbed;
        return YES;
}</code></pre>
<p>This code may be slightly tricky, but taken line-by-line it's not too bad. 'state' is a variable that keeps track of wheter the Paddle is already being touched. If so, we don't care if it is touched again, so we exit from the function, returning NO. Returing NO tells the touch dispatcher that some other object might care about the touch, but we don't, so pass it along.</p>
<p>We also check to see if the touch is actually on the paddle, and if it doesn't we again return NO, passing the touch along. How do we check if the touch is touching the paddle? Look at the following code:</p>
<pre><code>- (BOOL)containsTouchLocation:(UITouch *)touch
{
        return CGRectContainsPoint(self.rect, [self convertTouchToNodeSpaceAR:touch]);
}</code></pre>
<p>We're checking to see if a rectangle contains a point. If it does, the statement evaluates to true, and the function returns YES. The rect method follows:</p>
<pre><code>- (CGRect)rect
{
        CGSize s = [self.texture contentSize];
        return CGRectMake(-s.width / 2, -s.height / 2, s.width, s.height);
}</code></pre>
<p>The tricky thing about this code is that we are defing a rectangle based on the size of the sprite, relative to its anchor point. The default anchor point (0,0) is actually the center of the sprite, so this code actually defines a rectangle relative to the sprite, as if it had its own coordinate system, with (0,0) at the sprite's center.</p>
<p>In 'Paddle.h' we made rect a property, so we can use the dot '.' accessor to get its value.</p>
<p>The final piece of the puzzle is 'convertTouchToNodeSpaceAR:toch'. AR stands for 'anchor relative', so the touch is converted to the coordinate system of the sprite, relative to the sprite's anchor point.</p>
<p>So, if the touch is within the sprites rect, we change the 'state' variable, and return YES, telling the touch dispatcher that the touch belongs to us, and the touch should not be passed along.</p>
<p>Wrapping things up, you can probably see that in 'ccTouchesMoved' we change the position of the paddle if the paddle is grabbed.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9351</link>
			<pubDate>Tue, 25 Aug 2009 12:12:08 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9351@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>thanks, what about a dummy example including touch location?
</p></description>
		</item>
		<item>
			<title>cjl on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9348</link>
			<pubDate>Tue, 25 Aug 2009 12:03:43 +0000</pubDate>
			<dc:creator>cjl</dc:creator>
			<guid isPermaLink="false">9348@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/774'>Alex</a></p>
<p>Read Steve's response above. When the action triggered by the touch starts running you can set a flag (some people would use a variable of type BOOL):</p>
<p><code>running = YES;</code></p>
<p>Then, you can change your action so that it finishes with a callback to a function that resets the flag:</p>
<p><code>running = NO;</code> </p>
<p>Then, in your code that triggers the action you would need something like:</p>
<pre><code>if (!running) {
    //run actions here
}</code></pre>
<p>Anyway, that is one way to do it.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9347</link>
			<pubDate>Tue, 25 Aug 2009 11:43:57 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9347@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>how does one limit the touch so the action is completed before it can be restarted?
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9346</link>
			<pubDate>Tue, 25 Aug 2009 11:41:47 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9346@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>yeah, i would actually. one that implements CGRect and touch location if possible?
</p></description>
		</item>
		<item>
			<title>cjl on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9345</link>
			<pubDate>Tue, 25 Aug 2009 11:35:25 +0000</pubDate>
			<dc:creator>cjl</dc:creator>
			<guid isPermaLink="false">9345@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@Alex:</p>
<p>Sorry, I was 'sidelined' by my wife, for some reason she doesn't think iPhone programming is a top priority.</p>
<p>Do you still need a simple example? It looks like from your posts you have it working now.
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9344</link>
			<pubDate>Tue, 25 Aug 2009 11:33:24 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9344@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@Alex - you already have a model to follow in the code you posted.  Look at how they check if the paddle has already been grabbed.  You need to do something similar but check if your action is running.  Actions have an isDone method to check if they are complete or you could use a Sequence with a CallFunc action at the end that calls a method that resets a flag that will allow the action to run again.
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9338</link>
			<pubDate>Tue, 25 Aug 2009 10:08:50 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9338@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>how does one limit the touch so the action is completed before it can be restarted?
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9263</link>
			<pubDate>Mon, 24 Aug 2009 17:44:13 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9263@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Now it did, I must have missed something before ;-) Thank you.
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9219</link>
			<pubDate>Mon, 24 Aug 2009 14:34:34 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9219@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>That is strange, did it fix the warnings now?
</p></description>
		</item>
		<item>
			<title>alex on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9215</link>
			<pubDate>Mon, 24 Aug 2009 14:29:53 +0000</pubDate>
			<dc:creator>alex</dc:creator>
			<guid isPermaLink="false">9215@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/131'>Steve</a> Oldmeadow - u know I tried that before when I had all the warnings and it made no difference.<br />
Will have to work on consistency though ;-)
</p></description>
		</item>
		<item>
			<title>Steve Oldmeadow on "touch dispatcher for dummies?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/1420#post-9203</link>
			<pubDate>Mon, 24 Aug 2009 13:22:45 +0000</pubDate>
			<dc:creator>Steve Oldmeadow</dc:creator>
			<guid isPermaLink="false">9203@http://www.cocos2d-iphone.org/forum/</guid>
			<description><pre><code>id scaleto = [ScaleTo actionWithDuration: 0.5f scale:0.5f];
id actionBy = [ScaleBy actionWithDuration: 0.5f scale: 2.0f];</code></pre></description>
		</item>

	</channel>
</rss>

