top of page

Procedural Trade Lane Networks and Double3 class

For massive world space sims, everyone has to have a Double3 Class that works like Vector3 in Unity, it improves workflow and efficiency so much being able to add, multiple and subtract and divide Double3()s like their Vector3s, it's just one of the best things I've done for game development. Doing so makes it much easier to do more complex things, like procedural trade lane networks. I highly reccomend making a Double3 class, and overloading mathematical operators.

The procedural trade lanes was an interesting problem, because I wanted methods in the Start Method to be as efficient as possible, kind of my new thing, making the code as perfect and efficient as possible, that means like even nuanced things like not returning the curly braces after declaring a method, and absolutely no white space!

I wanted to make a trade lane script as efficient as possible, and for me that meant having a ffEnter, ffExit bool list, but after trying many times, I kept encoutering six degrees of Kevin Bacon in my implimentation, so I did a raw approach that works flawlessly, it's a really interesting math problem, trying to ascertain how many networks there are relative to the number of stations, it seems to be mostly irreducibly complex. There was no way I could figure out this proportion without running through my head each and every individual station, keeping track of where they were relative to all others. It's a great problem I think could be in a Martin Gardner book of recreational mathematics.

3 views0 comments

Recent Posts

See All
Post: Blog2_Post
bottom of page