Purplelilgirl Makes Games
Quick Review: Unity iOS Essentials

I am currently reading “Unity iOS Essentials”, which I won from ManiacDev’s book giveaway contest.

Unity iOS Essentials

And so far, I find that this book seems to be all over the place and it inspires to be a Game Design book.

Why made me think so? Well, Chapter 1 is about Planning Ahead for an Unity iOS Game, it starts out pretty clear, it aims to give the readers a little heads up before they start their game, it mentions considerations such as terrain, lighting, audio, etc. And then it got to the Let’s Get Started part, which is pretty much the author make all sorts of game design suggestions, and sometimes he would suggest something and not really explain why, such as he said that Fog is not such a great idea, and he suggests that we use particles instead, but why? Why isn’t fog a good idea? He even mentioned that it adds ambiance, so why isn’t it a good idea? Also there is a whole chunk that he talks about teleportation (wut? o.O), which provides means for players to travel across our large levels. He could have ended that bit there, but he goes on to suggest different ways of doing teleportation, warp gates, trains, what nots. And then after being distracted by all those really not important stuff, he starts talking about culling. Now, culling is important (even the author says so). But the reader could have skipped that part (okay, at least I almost skipped that part because I was skipping the trying to skip the teleportation part).

Chapter 2 is called iOS Performance Guide, but like Chapter 1, instead of getting right down to it (the performance guide), he starts the chapter with different kinds of games that the reader can make. And briefly mention skybox and how we’re supposed to use a cube with reversed normals instead of the one that Unity came with (again, no explanation whatsoever on why we shouldn’t use the Unity one). And then some bits about how we should do our terrain (not the technical part, the design part of making a terrain). Some more bits about different game genres.And then suddenly, Unified Graphic Architecture and the other stuff that actually seems like the iOS Performance Guide.

Chapter 3 is called Advanced Game Concepts, but really the things covered in the chapter is not very advanced, it’s stuff about menus, interface, screen sizes, accelerometer, shaders and organizing your assets.

Chapter 4 is called Flyby Background. Can’t say anything about it, because I skipped it.

I’m after Chapter 5 because it’s about Scalable GUIs, which I happen to be working on right now. So far, it’s understandable, pretty easy to follow. But the way the code bits are edited makes it somewhat unreadable. Oh and don’t expect the code to work as is.

That’s where I am right now, there are still four more chapters that I haven’t read yet.

So far, my comment is, it’s all over the place.

Link: http://www.packtpub.com/unity-3d-essentials-for-ios-games/book

ninjovee:

magnolius:

TarGetBooks Shelf - designed by Mebrure Oral, an Istanbul based industrial designer.

This special shelf is basically designed for separating the books that we have read and we will read. It shows you your target books all the time. You don’t need long books list anymore, just buy books on your target and put them on shelf and never forget and postpone your reading plans. It stimulates you, attracts your attention and encourages you to read more.

Oooh. Lovely!

Cocos2d for iPhone 1 Game Development Cookbook Giveaway Winners

So I used random.org to draw the winners… and the winners are… *drumroll*…

  • tetna
  • win_t
  • mishta
  • cocos2Developer

Since I allowed different ways to enter my contest, some of the winners on the list are from the cocos2d forums, while some are on Twitter.

So winners, please contact me (or check your forum messages or DMs) :)

Review: Cocos2d for iPhone 1 Game Development Cookbook

“Cocos2d for iPhone 1 Game Development Cookbook” is written by Nathan Burba (@nathanburba).

Cocos2d for iPhone 1 Game Development Cookbook
According to the description, it has “over 90 recipes for iOS 2D game development using cocos2d”. and just by looking at it’s Table of Contents, you’d see that this book covers a lot of topics (some advanced techniques that other cocos2d books have not covered). It also provides solutions to some common problems that we developers might encounter during Cocos2d iOS development.

Like in Chapter 1, it covers graphics, but unlike other books that would only teach you how to make sprites and spritesheets, this book even teaches you how to use apply mipmapping so that that when you scale up or down a sprite it wouldn’t look pixelated. It also has a recipe for a cool technique by swapping palettes so that even with limited amount of art, you can create various versions of a sprite (a single baseball player texture can have be used to create different baseball players with different colored shirts and pants etc). Chapter 1 also answers some questions that you might encounter while working on your game, such as how to I play a video clip of my company’s logo or my game’s cutscene (playing video files recipe). It also covers how to render 3D objects, drawing OpenGL primitives, particles, etc.

Chapter 2 is all about User Input on iOS devices, including the usual (tap, hold, drag), making virtual buttons (creating an analog stick recipe and directional pad recipe) and using the accelerometer. One really cool (for me) recipe that’s also included is gestures (you’d be able to tell what shape the user drew on the screen)!

Chapter 3 is about Files and Data. In making games, we’d need ways to store data (just us score, or level design, etc) and this chapter covers different ways for us to do this. This chapter has recipes for reading plist, json, xml data files, it also includes recipes about archiving objects, saving data using plist, SQLite, Core Data, etc.

Chapter 4 is about physics. Cocos2d has two physics engines that we can use Box2d and Chipmunk. This book only covers Box2d (which is the engine that Angry Birds used), it includes detailed explanations and recipes on how to set up your Box2d environment and simulating physics properties. it even includes a recipe on how to make a car drive up a bumpy hill road!

Chapter 5 is about Scenes and Menus. It also includes how to create buttons and labels (with fancy shadow effects even)! It also has a recipe for wrapping the UIKIT and using it in our Cocos2d game.

Chapter 6 is all about Audio: how to play background sound effects, play music, using the iPod music library. But the really fun bits about this chapter is it even teaches you how to record audio, create a MIDI synthesizer, and to top it all off, it even covers spech recognition and text to speech! Imagine all the games and apps that you can make with those things.

Chapter 7 covers AI, including waypoints, flocking using boids and A* pathfinding. it also teaches you how to run lua scripts and use lua scripts for dialog trees.

Chapter 8 is called Tips, Tools and Ports, and sure enough it includes information about tools that can be used for our Cocos2d game development. Best part, it also includes detailed step by step instructions of how to put your game on the AppStore!

Overall this is a good book with a lot of useful and varied information that have not been covered in other books (and are often lacking in online tutorials). Also
the best thing about this book is it comes with complete working code and detailed explanations on how the code works.

Except some of the topics covered in this book are a bit advanced, so this book is not recommended for beginners, basic Objective C and Cocos2d knowledge is required.

Also the author, Nathan is also very active in the Cocos2d forums, if you have any questions about the book you can just ask him, and he almost always responds immediately.

So if you’re interested to learn new things about Cocos2d iOS development, do check it out! Also if you are interested in this book, I am holding a giveaway contest (where I am giving away 3-4 copies of the book), join now (it’s only until this Wednesday). For more details read my previous blog post (http://purplelilgirl.tumblr.com/post/15713172087/cocos2d-for-iphone-1-game-development-cookbook-giveaway)

Unity 3D Game Development by Example Beginner’s Guide: Game #2

A few months ago, I wrote a blog post on #AltDevBlogADay reviewing a Unity3D book written by Ryan Henson Creighton, Unity 3D Game Development by Example Beginner’s Guide (buy the book, it’s pretty good, so far), but I only gotten around to Chapter 4.

Unity 3D Game Development by Example Beginner's Guide

So for this blog post, I will go through some of the other chapters, particularly Chapter 5 and 6, which is about making a game called “Robot Repair”.

Chapter 5 will talk about GUI (graphical user interface, pronounced as “gooey”, like marshmallows). And we’ll be making an entire working 2D flip n’ match memory game in the GUI system.

So let’s get started!

First we open Unity and create a new project called “Robot Repair”, we don’t need to import Standard Assets, according to the boss (Mr. Author, Ryan Henson Creighton).

So we have an empty slate (este project).

A Unity scene is a big 3D world, but we would be ignoring that for now. We will be using the GUI layer, which is like “a sheet of glass” in front of our 3D world.

We will be making 2 scenes for this game. A scene is like a level or a screen in our game. So two scenes, one for the title and one for the game game.

(how organized are we)

So we are making the title screen first.

(tada!)

Of course, so far the TitleGUI script is still empty.

And we type some code (este copy paste from the book):

And we get this:

And if you clicked the button, you get a lil message:

(yeah)

The book came with some code files and assets for each chapter, packed as Unity packages, just double click on the file and it’ll import it to your project.

For the title screen, the author has prepared a cute image that we will add as a GUITexture, and so we get this:

(oh, we also changed the position of the button, so it’s front and well, not really center)

And then hook the button to some code that will bring us to the game:

Application.LoadLevel(“game”);

(yes, this short little code will bring us to the next scene, if we have our scenes added to our build settings)

Lalala… okay, time to make the actual game game.

We go to the game scene (just double click on the scene in the Project panel).

And we’ll make a GameScreen game object and a GameScript script (like what we did with the title screen).

Ooh… what codes will we fill this new script with? *copy paste some codes from the book* Okay, and read up on the explanations too.

And we get this!

(whee)

And then we are done with one chapter. Look at us, pretty good, huh.

Mini Tutorial: How to batch replace textures with different file formats in Unity?

In relation to my previous tutorial: Mini Tutorial: How to batch convert image files to PVR (for iPhone app development)?

So you have a Unity project that was previously not planned for iOS (for PC, Mac or web or whatever), and you might not be as conscious of the texture file formats (iOS is probably the only one with so many constraints).

According to Unity’s User Manual:

Use iOS native PVRT compression formats. They will not only decrease the size of your textures (resulting in faster load times and smaller memory footprint), but also can dramatically increase your rendering performance! Compressed texture requires only a fraction of memory bandwidth compared to full blown 32bit RGBA textures.

So after converting all my textures (or creating a copy of my textures in .pvr format using Automator), I’m supposed to change all the material textures in my Unity Project and that’s a lot. So I wrote this tiny Editor script to do that for me. It will even delete the old texture (.tga or .png or whatever) from the Assets folder.

So here it is:

using UnityEngine;
using System.Collections;
using UnityEditor;                      
 
public class ChangeTexturesToPVR : ScriptableWizard
{
     [MenuItem (“Project Tools/Change Textures to PVR”)]
    static void MakeFolder ()
    {   ChangeTextures();
    }
 
    static void ChangeTextures()
    {
        string filePath = AssetDatabase.GetAssetPath(Selection.activeGameObject);
        int index = filePath.LastIndexOf(“/”)+1;
        filePath = filePath.Remove(index);
        
        foreach (Transform child in Selection.activeGameObject.transform)
        {    Material[] mats = child.renderer.sharedMaterials;
           
            foreach(Material mat in mats)
            {    string texFilePath = filePath;
                texFilePath = texFilePath.Insert(texFilePath.Length, “Texture/”);
                if(mat.mainTexture != null)
                    texFilePath = texFilePath.Insert(texFilePath.Length, mat.mainTexture.name);
               
                string oldTexFilePath = texFilePath;
                oldTexFilePath = oldTexFilePath.Insert(oldTexFilePath.Length, “.tga”);
               
                texFilePath = texFilePath.Insert(texFilePath.Length, “.pvr”);
               
                mat.mainTexture = (Texture)AssetDatabase.LoadAssetAtPath(texFilePath, typeof(Texture));
                AssetDatabase.DeleteAsset(oldTexFilePath);
            }
        }
       
       
    }
}

If your old textures are in “.png”, just change “.tga” in the code above to well, “.png”.

Select the model (.fbx or .obj file) whose materials and textures that you would want to change.

And then go to the menu and click Project Tools > Change Textures to PVR (yes, I created a Menu item for it).

And then voila!

Cocos2d for iPhone 1 Game Development Cookbook Giveaway

UPDATE: This contest is now closed

Like I mentioned in my previous post, Packt published a new Cocos2d book and they asked me to hold a giveaway contest. I’m holding it both here and in the Cocos2d forums (http://www.cocos2d-iphone.org/forum/topic/28099).

So here it is, rules, rules:

  • I will select a winner using random.org :)
  • Contest ends on 12 Noon Pacific Standard Time January 18th.

There, pretty simple right? :)

Also ManiacDev is also holding a book giveaway contest, he is giving away Unity3D and iOS books. If you guys are interested you can check out his blog: http://maniacdev.com/2012/01/giveaway-get-a-unity-3d-or-ios-book-there-will-be-6-winners-enter-here/

That’s about it :)

Cocos2d for iPhone 1 Game Development Cookbook

Packt recently released a new Cocos2d book: “Cocos2d for iPhone 1 Game Development Cookbook” by Nathan Burba.

Cocos2d for iPhone 1 Game Development Cookbook

Overview of Cocos2d for iPhone 1 Game Development Cookbook

  • Discover advanced Cocos2d, OpenGL ES, and iOS techniques spanning all areas of the game development process
  • Learn how to create top-down isometric games, side-scrolling platformers, and games with realistic lighting
  • Full of fun and engaging recipes with modular libraries that can be plugged into your project
  • Over 90 recipes for iOS 2D game development using cocos2d

Link: http://www.packtpub.com/cocos2d-for-iphone-1-game-development-cookbook/book

Missed Connections by Sophie Blackall
I got this book from my friend Len, who is in Vancouver, Canada.
It’s interesting.


Missed Connections by Sophie Blackall

I got this book from my friend Len, who is in Vancouver, Canada.

It’s interesting.

Assembling an electric fan - challenge accepted

3D Puzzle from Neil (disassembled electric fan). Since my boy genius friend (21 year old master’s graduate) just well graduated and will be moving back to the Philippines, he donated his electric to us. And the only way to transfer it from Taoyuan to Taipei is by disassembling it. I had no idea electric fans can be disassembled.

Do I need to have a degree in engineering to figure this out?

hmm… something seems wrong…

tight - righty tighty…

hmm… that looks right…

tighten - erm… lefty… loosey…?

drumroll…

Yeah! It works! I know have a degree in Electric Fan Engineering. :)

Palawan December 24 2011

We went island hopping!

Our first destination is this little hut in the middle of the sea, with a turtle roof. And our activity was snorkeling! (another first for me)

There were a lot of fishies swimming around us, it’s so pretty (unfortunately we don’t have an underwater camera).

The next location is an actual island. It’s called Snake island, because it is a long like a snake.

Free loader Stitch wanted a lot of pictures taken (including the ones I previously posted).

We snorkeled some more, fed fishies, took pictures (of ourselves) and had a picnic lunch on Snake island, before moving on the next island.

I found my (now) favorite sea creature on the next island (Pandan island): star fishies!

You can make them crawl on your hand! And stack them on top of each other to form a little Christmas tree (since it’s Christmas and all), but my little sister refused to take a picture of it (animal cruelty daw).

We had a quiet Christmas eve dinner at the hotel, where we had our favorite Filipino dishes: sinigang (a Filipino soup or stew characterized by its sour flavor most often associated with tamarind) and kare-kare (a Philippine stew made from peanut sauce with a variety of vegetables, stewed oxtail, beef, and occasionally offal or tripe), etc.

And that was how we spent our Christmas eve day.

While our Christmas day was actually our flight back to Manila.

And thus ended our trip.

Palawan December 23 2011

Included with our Cebu Pacific package is the Underground River tour and the Mangroves Paddle Boat tour.

We took a motorboat to the underground river. It was open sea, and the waves were pretty big.

The underground river is considered a wonder of nature and a natural world heritage site.

Here we go!

The water is brackish, which means it’s part sea water, part fresh water.

It was dark, the river is actually quite deep. You can see stalactites and stalagmites and bats. I got paranoid about 1: hitting the stalactites and 2: being pooped on by bats hanging from the ceiling 3: this area of the cave that has tarantulas that is how hell in my mind looks like and 4: accidentally falling in the river and drown. And it can’t help but remind me of a Nightwish song (2 songs actually, “Planet Hell” and its line “save a penny for the ferryman” and “Ghost River”).

Afterwards, we walked around the island and took pictures by the beach.

Including the pictures I used for my Facebook timeline.

We had a buffet lunch by the beach and then afterwards, we were supposed to have the Mangrove Paddle Boat tour (but rumor has it, they spotted a giant crocodile during a typhoon, so the tour was cancelled). So instead of the seeing mangroves, we went to Ugong Rock instead.

Ugong Rock is a cave, and the activities there included spelunking (also known as caving), rappeling and ziplining.

I am not made for extreme sports, but still I donned my hard hat and gloves.

Spelunking to the top of Ugong Rock!

The top of Ugong Rock! (aww my eyes were closed)

Only my little sister had the nerves to try the zipline.

The rest of us, rappelled down some parts of the cave to get back down.

And that was a day of firsts for me.

Palawan December 22 2011

We spent our Christmas this year a bit different, instead of our usual noche buena at home, we flew to Puerto Princesa, Palawan for four days and three nights.

Cebu Pacific had a promo wherein we booked our plane tickets, hotel room and Underground River tour for around 30k PHP for 4 people!

Puerto Princesa airport.

In Puerto Princesa, littering is strictly prohibited, so it’s so clean, compared to Metro Manila.

We stayed at Marina de Bay Resort and Spa.

We booked an additional City tour for the first afternoon, and a Honda Bay Island Hopping tour for the 24th (the day of the Christmas eve).

We went to this native weaving place, where my little sister tried to weave something.

We then went to Baker’s Hill, a bakery on top of a hill (lol) known for their quirky fairytale characters scattered all over the park.

We went to a wildlife and conservation center, commonly known as the crocodile farm, and saw (my mom kissed) crocodiles.

We also went to souvenir shopping and visited other short stops that day.

We went to this adorable restaurant, Kalui’s. There is no dress code, but everyone must go barefoot! Oh, you have to make a reservation, because it’s usually fully booked.

Enough of the setting, where’s the food?

I noticed they have different menus everyday?

Kalui is known for using fresh and natural ingredients. And they have to die for kilawin (accdg. to wikipilipinas: a Philippine exotic delicacy in which the main ingredient is raw fish or meat marinated in vinegar, pepper, chili).

A view of Puerto Princesa’s bay walk from our hotel.

Thus, ends the first day.


Stitch by the beach II
Honda Bay Islands, Puerto Princesa, Palawan, Philippines


Stitch by the beach II

Honda Bay Islands, Puerto Princesa, Palawan, Philippines

Stitch by the beach I
Honda Bay Islands, Puerto Princesa, Palawan, Philippines


Stitch by the beach I

Honda Bay Islands, Puerto Princesa, Palawan, Philippines

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25   Next »