• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
  • entries
    50
  • comments
    92
  • views
    65412

Game in 7 Days, Day 1: Still alive!

Sign in to follow this  
Followers 0
ManTis

1787 views

Holy shit, was it really half a year since I last posted here? Time flew fast.

My son was born (woo!), and I've had no time for absolutely anything at all, no sleep, no rest. Go figure. I have, as always, hanged out on #gamedev on afternet, but didn't code anything at home. These days, I'm finally setting into the role of parent and finally have time to resume programming for fun. I put a hold on my previous project, as it is bit big, but I was looking for some inspiration. I looked for it where I usually look - Ludum Dare website. I was lucky enough to find that it's happening this weekend. Time to warm-up then, right?

Last time I did 7 games in 7 days and it was a wild trip. I really enjoyed myself, but I don't think that I'll be repeating that when my kid is this young; I have some time, but not that much any more. So, new project would be 1 game in 7 days. I'm already way behind, with having only thursday and friday left for work, so it'll have to spill to next week, skipping for LD on the weekend (unless I feel like working on this game instead).

So, what's the warm-up theme? Take the first game you've ever created on your own (not by copy-pasting some tutorial) and remake it using the skills you learned along the way. First game? Woah, that takes me back.

First game I have ever created was Artillery (Scorched Earth for those of you that are bit younger, Worms for the ones that are even younger) clone written in BASIC. Funnily enough, I didn't realise back then that there was a QBASIC game that was exactly that: GORILLAS.BAS. I put it together in 45 minutes, during CS class in my primary school (I had a rich, for postcommunist Poland standards, school that could afford PCs in 1993), using a highschool physics book and throw equation for the shots. I didn't understand how parabolas were drawn, so I cheated: I calculated 'throw' distance (which was calculated using force of the throw minus the wind strength), max height of the throw, and drawn line from origin of the shot, to half the throw distance/max throw height, and then second one to max distance/ground level. It looked something like this:

0.png

Sweet game that, eh? ;)

Anyways, this meant that I'd be making artillery game again. Seven days gives me plenty of time to do very simple game. Let's see what's needed

1) Level generation
2) Character movement/physics
3) Weapons, Level Objects and Tools
4) Gameplay (as in, turn based stuff, killing, menus, GUI, etc)
5) Graphics
6) Audio
7) Polishing, cute stuff like crate drops with additional weapons
8) Multiplayer over net
9) AI

Seems like I've got my work cut out for me. I've written them in the order I'll be working on them. I want to make at least one point a day, so that I'll have functioning game by the end of the week (though it would be cool if I could fit in network play and AI). If nothing else pops out (I'm probably forgetting something), this should be doable. I'm trying to keep features/weapons/etc to bare minimum, to do the game on time.

Did I say that first dev day is done already? No? Well, it is biggrin.png

I knew that I want something more than just straight line. For a while I was wondering about using 1D Perlin noise to just have wavy surface, but decided against it. I wanted overhangs, like in Worms series. So, 2D Perlin noise it was. But first, I had to choose technology. I picked Unity3D, because I like it, and wanted to do some 2D game development in it, to test the sweet Unity3D 4.3 features. First thing I did was creating a Sprite from a hand-crafted texture. Poking and peeking like it's 1982! After some problems, I've had first result - white noise that changed based on height:

1.png

Once I had the technology down, I could start working on level itself. It took a 2D Perlin noise, added value between 0 and 1 (depending on height of the pixel on screen), clamped it to 1, and then added it to texture depending on a threshold value I picked, here's the very simple and unoptimised code: spriteRenderer = (SpriteRenderer)transform.GetComponent(); seedX = Random.Range(0,rangeMax); seedY = Random.Range(0,rangeMax); spriteTexture = new Texture2D(sizeX, sizeY); for (int x = 0; x < sizeX; x++) { for (int y = 0; y < sizeY; y++) { float color = Mathf.PerlinNoise((x+seedX)/resolution, (y+seedY)/resolution); color -= y/(float)sizeY; if (color < treshold) color = 0; else color = 1; spriteTexture.SetPixel(x, y, new Color(color, color, color, color)); } } spriteTexture.filterMode = FilterMode.Point; spriteTexture.Apply(); Sprite sprite = new Sprite(); sprite = Sprite.Create(spriteTexture, new Rect(0, 0, sizeX, sizeY), new Vector2(0,0),1); spriteRenderer.sprite = sprite; transform.position = new Vector3(-sizeX/2.0f, -sizeY/2.0f, 0);
And here's the result I got:

3.png

Now that I had level with overhangs, islands and floaty bits (not shown on this screenshot, basically blobs of ground hanging in the air) generated, it was time to add some texture to it. I have iterated over every pixel, and did a modulo of its position vs ground tile and some random offset. Then I iterated over every pixel that didn't have anything above it (surface pixel), and added grass tile line underneath, based on modulo of pixel's x position vs grass tile. And here's the effect:

4.png

And that was it for first day of development. I'll add some bottom layer (something on overhangs, analogue to grass on top of ground), and some simple customisability, and I'll be off to physics and movement code. See you then!

Day 1 summary finished, mantis out.

Story so far:

Day 7
Day 6
Day 5
Day 4
Day 3
Day 2
Day 1

6
Sign in to follow this  
Followers 0


0 Comments


There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now