• 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
    432
  • comments
    1166
  • views
    759172

Performance: GC is being made on a potato.

Sign in to follow this  
Followers 0
JTippetts

729 views

I haven't posted about GC in awhile. I have done work (most of it regarding the combat system) but a lot of the work is still "on paper" as opposed to "in the game".
The performance of the game has been a concern of mine for quite some time now. Granted, my dev machine is not a powerhouse. In truth, it is the polar opposite of powerhouse, unless your definition of "powerhouse" is "HP laptop from Costco with the finest integrated onboard Intel graphics." If that's your definition of powerhouse, though, you have worse problems than I do.
Anyway, the performance is crap. I mean, really. It's crap. I added the grass model you see in the shot above, and my framerate plunged to, like, 11. Sometimes 8. (This is in borderless full-screen, so 1366x768 on my lump of clay.) As you can imagine, testing out combat configurations and systems at these rates is frustrating, so often I'll disable vegetation and replace the hex tile material with plain white when testing that stuff. Still, in the back of my mind lurks the thought that it just isn't performant enough. People with roughly my system specs should be able to play a game of this level of graphical fidelity, and expect at least a somewhat decent level of performance.
I had fastcall22 do a test on his computer, and he said he was getting a pretty consistent 144 fps at 2560x1440 resolution. He's got a Nvidia GTX 1070 card. So, right now, about the best I can say is that depending on your system specs, you can expect somewhere between 5 and 144 fps playing my game. That's just... I don't know. Kinda scary.
What's the thought on ignoring shitty laptops from Costco with integrated Intel graphics? I mean, I know they're garbage. But still... 5 fps, on a machine purchased in 2015. Thoughts?
The alternative would be to scrap the quad-planar tile material and use traditional models, but everyone I talk to (including myself; yes, I talk to myself) likes the quad-planar tiles. They're kinda cool, and certainly unique. I don't really want to give them up. But if it comes down to that, or fielding a shitload of complaints about crappy performance, then I'd say I need to do what I have to. Assuming this thing ever releases, anyway, which given my glacial pace of development is looking highly doubtful.


6
Sign in to follow this  
Followers 0


7 Comments


The important lesson here imo is in future to be thinking about performance from the start, and as you go, and constantly monitoring as you add new features. The best way to work imo is to design according to your target platform, not design and then 'hope for the best' (many products have sunk this way). Consider not only average frame rate, but also frame spikes which could cause dropped frames.
That said :) , what is your target platform and graphics API? I'm guessing PC, which may mean you have more tricks available than if you were say, targeting OpenGL ES 2.
If you have access, try out a graphics debugger program to gain more info on what is bottlenecking and causing frame spikes. If you don't have this, try running the game with a very low resolution to see whether you are fill rate limited. If you are fill rate limited do what you can to reduce this .. e.g. optional simpler fragment shaders etc. If it runs slow even at low resolutions, look at how many draw calls you are making, how you are batching things, how you are optimizing static scenery, how complex are your vertex shaders / models, what method are you using for animation etc.
And it almost goes without saying of course profile profile profile for all the CPU stuff.


I already know the main source of the performance hit. It's the quad-planar hex tile shader. Substituting for the simpler one that just uses a texture-mapped model, I get plenty of framerate back (a solid 60 on my machine, which, really, no game I play gets any better than that.) It's just that damned shader is so heavy.

The shader uses a texture array of 8 different textures: 4 variants for the top of the tile (for grass, dirt, sand, etc...) and 4 variants for the sides (to mimic cliffs and whatnot). It uses a second array for normal maps. It projects textures along 4 axes: from the top, and 3 axes that are perpendicular to the 6 sides of the hex, in order to minimize the blending artifacts that traditional tri-planar projection causes on a hex.

That means that for each fragment I perform a total of 33 texture samples. I sample once on the blend map that determines terrain placement, then I sample 16 times (4 projection planes times 4 terrain types) for the diffuse component and 16 times for the normal maps. Then I blend all those samples together using blend factors calculated from the normals. It's a pretty complex shader, as far as fill-rate is concerned.
2

Share this comment


Link to comment
Discovered a funny thing while trying to fix an issue with running the game on eppo's computer. If I set compatibility mode to Windows 7 instead of 8, I get back in the neighborhood of 15 to 20 fps. Takeaway: Windows 10 suxors.
1

Share this comment


Link to comment
I've gotten some more information from eppo. He's getting around 40-ish fps on what he describes as a 'crappy' old CPU and a GTX 1050 Ti.

I'm feeling slightly better about things. The thing is, we all know most integrated Intel is crap for gaming. That's not a huge secret. I'm feeling better about putting less weight on my own performance specs now.

However, this has indicated to me that I need to get a build of this game into more peoples' hands, sooner rather than later. The build I had fastcall22 and eppo try is nowhere near where current development on GC is, though, since I needed to get something functional and fairly non-weird (current dev branch is... funky) together.
2

Share this comment


Link to comment

I like the idea that the game can run on a very old computer. Hope there is a Mac version. :)

0

Share this comment


Link to comment

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