Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 20 Jul 2013
Offline Last Active Yesterday, 08:52 PM

Posts I've Made

In Topic: What programming language should someone pair with LUA?

18 October 2016 - 07:30 AM

C++ is probably the commonest, more because game engines tend to be written in C++ than any other reason, although since Lua has pretty simple C-bindings, there are a plethora of bindings for other languages (http://lua-users.org/wiki/BindingCodeToLua)

In Topic: Types of Character Fighting Archetypes in RPG's

03 October 2016 - 12:07 PM

I don't see the Archer - mostly medium health, medium-to-good ranged damage, mediocre but ok melee

There's also often something like a Berserker, with lower armor and very high attack


There are also many shadings of combinations of these types.  For instance, a paladin is often a tank/warrior with some priestly abilities, or a ranger might be roguish and the ability to summon beasts, etc.

In Topic: How to put different textures on different sides of a Cube in DirectX 11?

02 October 2016 - 08:15 AM

How you would do this depends on how static the textures that you are applying are - do you want each side of the box to be different, but each box to be the same, aside from rotations?  If that is the case, then usually what is done is to create a texture similar to a 2D pattern that could be folded up into the 3D box shape, and UV-map the faces of the box to match the texture.


For instance:


In Topic: Possible to do LOD terrain with hardware tessllation?

02 October 2016 - 06:17 AM

Frank Luna's DirectX 11 book has a chapter on using the tessellation hardware support (Hull and domain shaders) to do a dynamic LOD tessellation of a simple quad mesh based on a heightmap texture.  If you don't want to buy the book (which I would recommend, it's a pretty good resource for learning Direct3D 11), you can download the code samples from his site http://www.d3dcoder.net/d3d11.htm, Chapter 19.

In Topic: Coding-Style Poll

27 September 2016 - 12:41 PM

If I was going to implement a standard formatting style, I'd look into some kind of source-control commit hooks that could run new/modified files through a formatter, and enforce it that way.  Automate the tedious part, somewhat like what gofmt does.


But as to my own preferences:

  • Opening braces aren't special, and they don't get their own lines.  Likewise, else, catch, finally, things like that, live on the same line with the closing brace of the previous block.  Otherwise it's just too much wasted vertical space.
  • Everything that can have braces around it should.  No exceptions for one-line if's, and definitely no same-line ifs.  I even like to put braces around my switch-case blocks, especially in languages where braces create a new scope.
  • Interfaces can get the I prefix.  Private member variables start with _.  Properties are capitalized, regardless of visibility.  Locals and function parameters start with lower-case.
  • GUI controls get Hungarian-ish prefixes, since I started programming with Visual Basic, and it was always taught txtFoo, lblBar, etc.  I kind of like it anyway, even for things like HTML element ids that get used in Javascript.
  • Don't bother fully-qualifying variable declarations if type inference can figure it out -> LongObnoxiousEnterpriseGangOfFourPatternAbstractFactoryFactory = new LongObnoxiousEnterpriseGangOfFourPatternAbstractFactoryFactory() blows.