Procedurally Generated Content in Crooked

New releases and general discussions.

Post » Sat Mar 14, 2009 11:08 pm

Not sure about curves at the moment, Mipey's right, if only key points of a curve are stored in the array then I'll have the curve going over some things on the array - if the curve is stored in two points on both ends, with the curve in the center, then the generator might think those center squares are grass or something. I could do it old school like curves in those old Transport Tycoon games - where a curve is actually like a gigantic L shaped tetris piece on the array, but visually pleasing in the world. Even then though, buildings won't be able to come flush up against the road for instance. It's something to think about, but definitely a tricky situation.

Right now deadeye has me concerned with sidewalks and street paint and all the gritty stuff involving getting those roads and intersections looking like roads and intersections instead of ... well ... sprites on an array. :P
B
5
S
2
G
5
Posts: 221
Reputation: 2,272

Post » Sat Mar 14, 2009 11:59 pm

Well I wish you luck, and encourage you to try curves at some point. Box worlds can only take you so far, and for a car game that distance is a bit shorter ;)
B
2
S
2
G
5
Posts: 391
Reputation: 2,432

Post » Sun Mar 15, 2009 5:03 pm

More progress, looks much more professional. Threw in some props for Construct as well should anybody stumble across the movie while crawling through Youtube videos. Deadeye was telling me that some extra muscle around here would be good for the program.

http://www.youtube.com/watch?v=D_wFy7L3D7U

I'd actually done a rudimentary traffic model at the time this footage was taken, but I based it on the "grid" movement behavior, and I think bullet would be better. Grid is much easier to use, but it's kind of hard to get them to stay in their lanes when they are turning. I turned it off for the footage.
B
5
S
2
G
5
Posts: 221
Reputation: 2,272

Post » Sun Mar 15, 2009 6:18 pm

Wow. That is impressive. I do hope you'll write a tutorial someday. :D
B
2
S
2
G
4
Posts: 136
Reputation: 1,722

Post » Sun Mar 15, 2009 9:17 pm

i'm looking forward to your progress! please check your videos for the correct aspect ratio next time, so your video diary is less irritating to watch.
B
2
S
2
G
4
Posts: 171
Reputation: 1,792

Post » Mon Mar 16, 2009 10:51 pm

[quote="dkdoom":24t0kjz8]i'm looking forward to your progress! please check your videos for the correct aspect ratio next time, so your video diary is less irritating to watch.[/quote:24t0kjz8]

Sorry about that, had it in 1000x1000 from back when it was little dots and the whole city was 1000x1000 pixels. Got it in a regular ratio now.

At the moment I'm focusing on the buildings. I decided that I want everything kind of stylized when I'm done, so I'm going to be using Google Sketchup to design the buildings and screenshot each side to texture their outsides, I'll probably use it to model their interiors and probably the furniture in there as well. It's a nifty little program created for designing architecture - for people who can't design/model/do art...such as myself. :P It was originally created for Google Earth, to get more 3D buildings on their map.

Apparently it can even turn a picture into a 3D model or something. It's a really cool program, I think I'll enjoy using it.
B
5
S
2
G
5
Posts: 221
Reputation: 2,272

Post » Wed Mar 18, 2009 7:17 pm

[quote="Arsonide":1qlu8fhv]... model their interiors and probably the furniture in there as well.[/quote:1qlu8fhv]
:shock:

your intended level of detail is mind-boggling... but why would you want to model the interiors by hand when you could create them procedurally, like your city?
B
2
S
2
G
4
Posts: 171
Reputation: 1,792

Post » Wed Mar 18, 2009 7:23 pm

I believe his missus likes decorating interior... even if it is virtual. Ya know, women. "Honey, which one for the curtains?" "Umm, red?" "Nah, blue is more relaxing." "Okay, as you say."
B
62
S
21
G
12
Posts: 1,910
Reputation: 13,155

Post » Thu Mar 19, 2009 4:33 am

[quote="dkdoom":3l0mahj3] :shock:

your intended level of detail is mind-boggling... but why would you want to model the interiors by hand when you could create them procedurally, like your city?[/quote:3l0mahj3]

Interiors will be based on maps, but the content will be procedural. For instance, there will be 100 interior maps for "LightResidential" buildings...but the furniture placement in there will be randomized in each one, even if you find the same map twice.

The game goes into sidescrolling mode when you enter a building. Modelling stuff in Sketchup ensures that buildings are consistent both on top and from the side. :)
B
5
S
2
G
5
Posts: 221
Reputation: 2,272

Post » Fri Mar 20, 2009 5:02 pm

This will be my last update to this thread on progress on the program. I don't want to keep bumping this thread to the top of the forum. I will be making a simple blog for progress on the game in the coming days, and put it in the original post. That way anybody interested can see my progress, and anybody not interested doesn't have to deal with my thread being on top all the time. :P

Last night Deadeye gave me a lot of really awesome performance tips. Seems that events don't have to have the Always condition to fire every frame. It also seems that comparisons done on an object will always pick the initial instance of that object and no further ones - unless you pick by comparison. Once this was hammered into my skull, my performance problems vanished...and knowing this I have a lot of refactoring to do. My program also has become frayed with features. There are a lot of features implemented, but a lot of loose ends to tie. For instance, the MacroGenerator - the process of generating the city's basic layout - is using globals right now. I need to migrate it to using private variables on a MacroGen object, because using ten globals for a process that happens once is bad design. I'm really afraid to start doing this, I've attempted and given up several times now...because there are several hundred references to these variables and one typo can screw up a lot of things. (Yes I am using Find and Replace, but a lot of it has to be done by hand as well.)

The only way I can make it easier is with liberal commenting and group usage. If I comment every line, then if one is broken it will be more easily identifiable. So refactoring, and tying up these loose ends is my highest priority right now...I won't be adding any new features until MacroGen and MicroGen are working exactly the way I want them to, and I feel there are no more loose ends on the program. Then I will continue expanding on what is there.

Last night as deadeye explained things to me a very simple concept for a map popped up into my head, and I figured it would speed development time to have one - a lot of my debugging time is spent looking for a road if I happen to start on grass. That was a thinly veiled excuse to ignore my refactoring pledge and add a map though, here is a quick four second clip of the concept: http://screencast.com/t/qbxdEh2bW

I use Jing to quickly capture video and images, it lets me basically hit control-shift-s and designate a cropped area on my screen, capture, and upload in a matter of seconds. It makes really crappy videos though, so for the longer Youtube videos I use other capture software, but that takes a lot of editing time. For quick four second videos, Jing is fine. :P

EDIT: Started the Blog! It is here. I have to go to work at the moment, so it's something I whipped up in a few minutes. I'll polish it up later. Oh and yes - my character's view of the world is inspired by Rorschach's.
B
5
S
2
G
5
Posts: 221
Reputation: 2,272

PreviousNext

Return to Construct Classic Discussion

Who is online

Users browsing this forum: No registered users and 1 guest