Sponsored By

Path finding with dynamic scaling

Making a point-n-click adventure game is useless without a path finding algorithm. So we started with what is called the A-Star or A* algorithm, and then tweaked the hell out of that.

Cathy Pyle, Blogger

January 2, 2020

3 Min Read

Greetings Giggle Horse fans! I know that the last few blogs haven’t been so much about Absolute Zero, as the Cortex and Legend engine, but we will get back to that soon enough. For now, it is important that I lay down all of the technology we developed to get to a place where Absolute Zero was even possible. That meant taking the output from Legend and shoving it all through the Cortex engine to make something that resembles a point-n-click adventure game. So the first place I started was with a point-n-click path finding algorithm.

Making a point-n-click adventure game is useless without a path finding algorithm. So we started with what is called the A-Star or A* algorithm, and then tweaked the hell out of that. If you want to understand this algorithm more, please click on this link about A* algorithms.

Then after modifying it, we multithreaded it and prioritized it so that if you are traveling to one place, and click on another, it will disrupt the first path and divert to the new path. In a nutshell, this keeps you from clicking on stuff, and yelling “Damn it, I didn’t want to do that” without recourse. With out algorithm, you can click on the wrong place, and yell, “Damn it!”, them immediately click away and the crisis is averted! Take a look at this demo video to see how it works. Keep in mind, this is footage of the “First” ever path finder using Cortex and Legend.

This algorithm was also designed with “Dynamic scaling” implements so that a character, or anything traveling in the environment will be proportionally scaled to its Z depth (scaled based on how close or far it is from the camera). Also notice the dude, we call him Norman, was created to appear occluded by objects that are closer to the camera than he is. The scene is pretty grainy, but that is because we didn’t care, and just wanted something to test the algorithm with. This really was the largest step towards creating a real point and click style game.

I also wanted to test that Norman could move from one scene to the next, and dynamically scale as he ended up in any new scene. So I created a tiny little restaurant sort of a thing that I could render out in like 30 seconds. So below are the rooms that I created for what I call “Norman’s Restaurant”.

Main dining area   Wanna be kitchen area you could never cook in   Lounge to the left of the diner  

Come hang out with us and talk about all sorts of things gigglehorseforums.com.

GiggleHorse Twitter Facebook YouTube Instagram LinkedIn

Read more about:

Blogs

About the Author(s)

Daily news, dev blogs, and stories from Game Developer straight to your inbox

You May Also Like