Tag: Sprite

  • Re-doing Dungeonators

    One thing I think all software developers love to do is to make software for “the heck of it.” Hacking something together without having to worry about users, open source community members, and code reviews, is something devs don’t get to do often in these days of test-driven, agile, minimum viable products. Back in 2011…

  • Sprite Playground

    I wrote a little Cocos2d-iPhone test app and committed the project to GitHub. (Like every dutiful hacker should.) You’re welcome to download the project and fool around with the code. My goal was to figure out how to create a composite sprite, make sure it could respond to touches, and rotate and move it round…

  • Cocos2d-iPhone Sprite Rotation to an Arbitrary Point

    I had some time during the Thanksgiving weekend to work on Dungeonators. I’m hoping to get an upgrade out to the App Store soon. One thing I needed //TODO: is refactor my rather poor implementation of rotating a sprite to face another sprite. My original code worked ok, in a roundabout way, but was ugly…

  • Cocos2d Tip #2: Using CCTimer in Your iPhone Game

    If you’re writing almost any type of game, from a puzzler to a FPS to an RTS, tracking time is critical element of the game play. (Except for Angry Birds. You can ponder an Angry Birds level until your iPhone battery runs dry without penalty.) Cocos2d-iPhone provides several means for tracking time in your game…

  • Cocos2d Tip #1: Changing a Sprite’s Image Simply

    I’m writing an iPhone game using the Cocos2d-iPhone framework. It’s been smooth sailing except for one little detail: I want a sprite to change it’s image based on a touch. I think the problem is that there are a dozen ways to do this in Cocos2d. I wanted to find the simplest way to do…