Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411426 Posts in 69363 Topics- by 58416 Members - Latest Member: JamesAGreen

April 19, 2024, 09:35:28 AM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsPrune - Released!
Pages: 1 [2] 3
Print
Author Topic: Prune - Released!  (Read 13712 times)
Blambo
Guest
« Reply #20 on: September 12, 2014, 09:36:14 AM »

totally dumb thing that's bothering me is that shadows darken ones that they're overlapping, which doesn't ever happen with one light source. but otherwise i'm loving the look and feel of everything.
Logged
William Chyr
Level 8
***



View Profile WWW
« Reply #21 on: September 12, 2014, 10:51:12 AM »

I kind of like that the overlapping shadows are darker - may not be the most realistic thing, but I think it helps with readability.

Anyway, these new screenshots and gifs look great! I especially love the trail of light that the sun leaves behind.
Logged

Pemanent
Level 4
****



View Profile
« Reply #22 on: September 12, 2014, 10:58:23 AM »

damn this is cool as hell. I love it. Definitely following.
Gonna say you shouldn't have the shadows double darken like that. I think it would look cooler if they didn't anyways.
Logged

ryansumo
Level 5
*****



View Profile WWW
« Reply #23 on: September 12, 2014, 04:53:07 PM »

Glad to see this game progressing.  Looking forward to your future updates.
Logged

noethis
Level 0
**


View Profile
« Reply #24 on: September 13, 2014, 06:32:16 AM »

Yep, assuming I decide to continue with the shadows I'll most likely kill the double darkening effect.
Logged

Kyle Preston
Level 2
**



View Profile WWW
« Reply #25 on: October 02, 2014, 12:56:51 PM »

As an Astronomy/Historical lore nerd, it totally reminds me of Ptolemy's geocentric model.



But much prettier. Keep up the good work, looks great!  Smiley
Logged

noethis
Level 0
**


View Profile
« Reply #26 on: October 03, 2014, 08:40:31 AM »

Haha, didn't even realize... I guess my mind is still living in pre-Copernicus times.
Logged

metlslime
Level 0
***


View Profile
« Reply #27 on: October 03, 2014, 11:58:39 AM »

The art looks great and the concept is appealing to me.

I don't understand the gameplay yet but I look forward to seeing more of this.
Logged

Julien
Level 2
**


View Profile
« Reply #28 on: October 03, 2014, 12:01:12 PM »

I really like this idea ! Very original !
Logged

ephoete
Level 2
**


View Profile WWW
« Reply #29 on: October 05, 2014, 07:02:00 AM »

Wow pretty neat and original. There was another thread here that was about trees that I haven't seen for a while. Is there any connection with this project? That really evokes me the same engine that the guy had made.
Logged

Check out my Soundcloud! https://soundcloud.com/edgar-phoete
noethis
Level 0
**


View Profile
« Reply #30 on: October 05, 2014, 07:58:15 PM »

Only one I know of is How To Be A Tree. If there's another one I don't know about I'd like to see it! Smiley
Logged

noethis
Level 0
**


View Profile
« Reply #31 on: October 06, 2014, 12:35:36 PM »

DevLog Update – Grass/Fur/Spines/Noodly-Appendages
Threw some grass at Prune the other day and it kinda stuck. Well, 'grass' is a generous term for what came out. Whatever you want to call it, I'm definitely enjoying fiddling with parameters to make it do different things.

Not sure if I'll do anything with it other than use it for cosmetic detail. It's not currently prunable (soon though) and needs to be optimized a ton, but it works as a proof of concept.

I *probably* shouldn't have been adding grass when I've got important game-wide decisions to make, but I find it useful to have fun little tasks saved up for "rainy days." In times when I get stuck on a project and start taking the downward spiral, these guilty pleasure tasks can sometimes help get me back on the rails.







Logged

ephoete
Level 2
**


View Profile WWW
« Reply #32 on: October 07, 2014, 12:49:46 PM »

Only one I know of is How To Be A Tree. If there's another one I don't know about I'd like to see it! Smiley

Oh yes that's the one I had in mind right! So different persons, different projects.
Logged

Check out my Soundcloud! https://soundcloud.com/edgar-phoete
Julien
Level 2
**


View Profile
« Reply #33 on: October 07, 2014, 12:57:11 PM »

DevLog Update 03 – Optimization
You wouldn't think a simple game like Prune would need any optimization at all. I mean, it's basically one tree and some circles. But there are three things you have to realize: 1) I'm a terrible programmer, 2) trees tend to have a lot of moving parts, 3) see #1. I've become quite skilled at hacking together barely functional, terribly inefficient code in the name of "prototyping" and then moving on.

When I first started prototyping things, I didn't really see any slowdowns on my PC so performance wasn't even on my mind. But then when I tried it out on my iPad 2 for the first time, it brought it to its knees. So I started reading up a bit on mobile performance and found I was basically doing everything wrong.


Put Your Draws Down
First order of business was to get my draw calls down. Turns out, keeping draw calls low is *super important* for mobile. For whatever reason, my branches were initially made out of quads instead of proper 2D sprites (in Unity). As soon as I would override the material color (e.g. - infecting a branch red), the draw call count would go crazy. Instead of a pleasant number like <50, it would spike up to 500 or so to match the number of tree branches.

Luckily, this was an easy fix. After messing around with trying to batch the quads and use a shared material, I found simply switching to sprites took my draw calls down to the single digits where they should be for a game with a single silhouetted shrub.


iTween, uTween, weAllTween
Since I had used iTween on other projects, I naturally began using iTween to animate all the tree branches growing. Again, this was pretty much fine on PC, but as soon as I tested on mobile I found that iTween'ing 500+ objects in parallel was A Bad Idea due to the considerable overhead. I quickly found a much faster alternative in LeanTween.

I also ended up just writing my own simple little loops for lerping stuff like branch color and branch size since I wanted it to run as fast as possible and allow for Prune-specific stuff.


You Get A Collider, YOU Get A Collider...
For my initial prototype, I made the (hasty) decision that each branch would get a box collider (set to trigger). My branches were rectangles, so they deserve box colliders, right? Of course, this was overkill, but I didn't know it at the time. It made things relatively easy to get in quickly since I could just add a bunch of OnTriggerEnter type calls.


After awhile I realized that all I really needed was a line segment to define a branch, so I switched over to Unity's Edge Collider 2D. This, combined with realizing I needed to add RigidBody components (oops), ended up improving performance quite a bit.



So Many Branches
But all was not well in framerate land, I was still having major framerate drops on my iPad. I knew the number of branches trying to update at once was a problem. Early on, I went from a tree depth of 9 to a depth of 8, which basically cut my branch numbers in half (~500 instead of ~1000). This was an easy change because that final layer of teeny tiny branches was pretty much invisible anyway:


But I wasn't willing to go down any further in tree depth. I still somehow needed to update fewer branches every frame. My hunch was to implement some sort of round-robin system, and after talking it over with Aaron San Filippo, I decided to try it. Dividing the branches into 3 "pools" and then having them take turns updating helped immensely.


Throwing Out Collision
Things were feeling pretty good now. But I'd still get the occasional slowdown, especially in certain "worst-case" scenarios. I wanted the framerate to be ultra buttery smooth and it was not always ultra buttery smooth.

Relatively early on, I switched from a collision based "swipe" to a manual line segment intersection based swipe when pruning. This did wonders for the precision and reliability of pruning:

In the back of my mind, I knew that I probably needed to take this approach with all my branch "collisions." I knew the best solution would be to just get rid of branch collision altogether in favor of writing custom "collision" code for my situation. Well, I finally got around to doing this last week and I can say that I'm now pretty darn close to ultra buttery smooth!


Future
I'm trying to avoid the whole "premature optimization is the root of all evil" thing, so I won't be doing these things if I don't have to, but two further areas I could optimize are:
  • Budgeting/throttling - Place an upper limit on how many things can be updated in a single frame. Queue for later anything that exceeds this limit.
  • Space partitioning - Divide the playspace into cells so that when doing my custom collision checks I'm only checking branches in the neighborhood.


So there it is. I'm probably missing some really obvious optimizations, but I do feel like I've learned a lot in the process. Plus, it's even kind of fun to squeeze out another few milliseconds (did I just say that?).


Just read this post. It was very instructive Smiley Actually bookmarked it for whem I would start Unity
Logged

noethis
Level 0
**


View Profile
« Reply #34 on: November 12, 2014, 11:29:30 AM »

DevLog Update – Rethinking Pruning

Been quiet the past few weeks but I have, in fact, been working away! After doing some playtesting back in October I realized that I was starting to get away from what the core of the game should be--the Joy of Pruning. In the name of exploring the design possibility space as fully as possible, pruning ended up getting neglected a little bit.

So I've spent the last couple weeks focusing on how to make pruning more interesting and expressive for the player. The biggest change required me to rethink how the trees in Prune grow. The way I originally wrote the trees allowed for randomness in the details, things like branch width/length/angle, but the trees were, essentially, stuck inside a "box." Pruning was purely a subtractive process.

I realized that the tree needs the concept of "energy," a limited resource they would pull from for growth. Of course, this models the way that real life trees work to some extent--their resources happen to be water, soil nutrients, and sun. Armed with this new energy model, pruning becomes more about redirecting the tree growth rather than purely lopping off branches.

Seems really obvious, doesn't it? But sometimes you get so entrenched in the way you're doing things that you miss the obvious.

Anyway, here's an example of how you can now "stretch" a tree upward out of the shadow, simply by pruning:




Logged

noethis
Level 0
**


View Profile
« Reply #35 on: November 13, 2014, 06:58:49 AM »

Here's another GIF showing how you can now get out of tight spaces:


(sorry 'bout the file size--haven't figured out a way to compress the gifs down w/o butchering them)
Logged

JackMenhorn
Level 2
**


Sound Designer


View Profile WWW
« Reply #36 on: November 17, 2014, 05:39:36 PM »

Those gifs really help out in showing whats going on. super rad!
Logged

Sound Designer<br />www.jackmenhorn.com

Nova-111 OST: https://jackmenhorn.bandcamp.com/album/nova-111
noethis
Level 0
**


View Profile
« Reply #37 on: December 05, 2014, 03:06:46 PM »

DevLog Update – Terrain

So you may have noticed from the last update that I've introduced various forms of natural terrain for the trees to grow around--cliff faces, overhangs, etc. At first I was really hesitant about this--clinging with a death-like grip to my precious abstract circles and ground. But I pretty quickly realized that using *just* circles led to a lot of ridiculous looking situations. The tricky thing is that Prune sits in that awkward space between fully abstract (Hundreds) and fully realistic (whatever "realistic" means in a video game). So it's not like I can just go gung ho towards one side or the other--it's about striking that balance.

Whatever I go with needs to mesh well with the abstract red and black circles that are already in the game. Also, I need to be super careful not to start down the "realism" rabbit hole by throwing more and more detail at it. Sure, games like Limbo/Badland look great with their detailed silhouette environments, but I have neither the time nor talent to go that far.

With that in mind, I've explored a few different possible styles of terrain. I'm not super happy with any of them at the moment, but I thought I'd post them here to get others' thoughts.


Logged

Kyle Preston
Level 2
**



View Profile WWW
« Reply #38 on: December 07, 2014, 01:38:06 PM »

Number 2 and 4 are my favorites, but if you twisted my arm I'd probably suggest 2; seems like the right amount of raggedness, which creates a more dangerous looking obstacle.
Logged

jgrams
Level 3
***



View Profile
« Reply #39 on: December 08, 2014, 05:00:14 AM »

I like number 2 best, since it matches the starkness and simplicity of the trees. The swoopy curves and more complex edges of the others don't match either the trees or the circles, which feels like a stylistic clash to me...although they're cool in their own way.
Logged
Pages: 1 [2] 3
Print
Jump to:  

Theme orange-lt created by panic