Tag Archives: programming

Recommended Reading: RunTime C++ Scripting

Interesting bit came up at work with our bi-weekly “brown bag” lunches with our programming team – Scripting vs Native C++ code. A lot of game developers, and even in many other realms, some of the code base may be split into Lua or Python for easy, quick iteration. I know many studios, such as many of the Call of Duty studios, use primarily Lua for their gameplay scripts.

The argument is that is easy to write, iterate fast, and provide to employees who don’t have deep programming knowledge (like some gameplay designers and such). It’s perfectly legitimate too, there isn’t anything inherently wrong with the scripting languages augmenting a huge C++ code-base engine. However, there are caveats such as managing two different languages and creating wrappers for stuff. Also, Lua doesn’t have proper debugging tools many C++ programmers are used to, and when tied into that code-base, it can become a nightmare to debug.

Enter C++ code thats runtime-compiled and used as a scripting language.

Fantastic read, pretty classy too. Each script is a single cpp file that gets compiled into a dynamic library which recompiles everytime the file changes, even during gameplay. The scripts even get a nice little compression size reduction too. Good read.

Ubisoft Montreal GameJam 2014 – “You & I”

Team Omega’s Ubisoft GameJam project – “You, Me, Pigs In A Forest”

A spooky co-op game that features the theme of “You & I”.
One player controls a lantern and the other a sword. Enemies cannot be hit with the sword unless they are vulnerable from the lantern light. The lantern player is powerless to defend himself and the sword player has no light source. They must stick together to survive but are sometimes forced to separate.

Using Unity Pro, we employed depth of field and noise filters to create a cinematic quality to the darkness.
A custom shader I made gives maps a “fog of war” where shadows envelop the player, and only the lantern has the ability to shine through. If the sword player moves out of the lantern, the darkness completely covers him.
Enemies employ the Unity nav mesh system to follow and hunt the player down in swarms.

jpeg

Book Review: Effective C++

Effective C++ by Scott Meyers has been around for awhile and it is pretty revered. With good reason. It is one of the books a lot of C++ programmers, both beginners and adept, read and then never look back after. After being recommended the book several times, I finally got around to picking it up.

Unlike a lot of other programming books, such as the ones I’ve previously reviewed, this isn’t a tutorial or “how-to” C++ book. So there is some technical requirement for the book and if you don’t have interest in C++, it probably won’t do much for you. But if you want to check it out, my review can be found after the break.

Continue reading

Book Review: iOS7 Game Development

iOS7 is Apple’s latest update to their mobile OS at the time of this writing. With it came huge changes for consumers and developers. Namely ‘flat’ design came about and the entire iOS interface was redesigned with new visuals. The change meant new features for developers too such as SpriteKit – the new 2D game development framework.

iOS7 Game Development by Dmitry Volevodz from Packt Publishing demonstrates how to create an endless runner using the new SpriteKit framework

Continue reading

Today I Learned: Never Rely On Memory – Let The Code Do It For You [If You Can]

So this is something I’ve seen two large camps pitted against each other for. Programmers should always be responsible for the code they write and should always be actively trying to write responsible code in itself. I think everyone can get behind that without much quarrel. But! One camp tends to argue that the programmer should ensure there is ~absolutely~ no way for things to blow up while the other camp argues that the programmer should place ‘checks’ in the code in the possibility that it does.

Hopefully the issue is clear.

Should a programmer place checks in their code to not only protect users in the future, but also themselves? “Why wouldn’t you?” your reaction may be. Well, you might have a complex piece of code that would take a lot of resources to constantly check will work properly. The goal is to make sure your code is exception-safe as much as possible, but there is always someone out there who will holler out “at what cost?!” If something is expected to work one way, that should be the ~only~ way it will ever work they argue!

It boils down to a kind of elite purist paradigm vs a human-error safe paradigm. Both have merit!

I made a pretty timely and amateur mistake today because I was running the purist paradigm. I’ll talk about how I should have placed checks to save myself and evidently my boss about 2 hours of time. But at the same time the issue could’ve been easily avoided and no check at all would’ve been needed if I didn’t rely on my faulty memory.

Continue reading

Book Review: CryENGINE Game Programming with C++, C#, and Lua

CryENGINE is the popular and insanely powerful game engine used in games such as Crysis, Ryse, and originated with Far Cry 1. Developed by Crytek,  it supports the latest and greatest visual renderers such as DX11. CryENGINE 4 is coming soon as well as Linux support. A modified version of the CryENGINE spawned the Dunia Engine, which is used by Ubisoft Montreal for Fary Cry 2 and 3.

I wanted to try my hand at playing around with the famous engine and thus I am reviewing  CryENGINE GameProgramming with C++, C#, and Lua by Filip Lundgren and Ruan Pearce-Authers, published by Packt Publishing. Read on to see how it went.

Continue reading

Today I Learned: Connections Can Come From Anywhere

So GDC 2014 starts this Monday and as much as I want to go, I only went last year to shoot for an awesome internship. The people, the booths, the information were all great but its hard to justify the cost to get down there right now especially now that I do have an awesome internship at Ubisoft.

But something hilarious happened today in relation to GDC and, to some it might not be a big deal, but to me its just… WOW the coincidence. And its just so inspiring and now if I truly had the money, I’d jump right back on the plane to GDC again.

Continue reading

CryENGINE GamePrograming with C++, C#, and Lua Review Incoming

Hey everyone,

Soon I will have a review up for CryENGINE GameProgramming with C++, C#, and Lua by Filip Lundgren and Ruan Pearce-Authers, published by Packt Publishing.

It will be reviewed in the same style as the Unity Multiplayer Games review, and maybe I’ll make this a regular thing to review books I’m given or happen to pick up! Expect the review up this weekend or so.

Sample Chapters

Today I Learned: WPF Templates

Ugh XAML. Functional its really nice, and with Windows Presentation Foundation, it makes for some really awesome GUIs. You can do all kinds of cool data binding and automatically display information. A few projects about a year or so back using WPF XAML and C# is what reinvigorated my love for programming, which admittedly was looking down for awhile. But damn is it messy. Quick example: You can make an excel grid automatically display the data members in your class. If you had a class of Customers, with all kinds of Customer info, you can bind the grid to a list/array or collection of Customer and have it automatically display this info. So awesome! But, what if you wanted a specific kind of grid with specific properties? Continue reading

Today I Learned: Const All The Things

Welcome to a new column I plan on making semi-day (possibly weekly?), providing I get the chance to.

Today I Learned: Const.

Const all the things. Const the variables, const the function, const the members in the function,  const even if you want to modify the data later until you get to the point you need to modify data and work backwards because plans tend to change.

CONST