13 Actions

Pure functional programming and game stateIMO, functional languages are poorly suited for writing games. This is one of many problems that you will need to solve. Games require very precise control of performance, and rarely have good concurrency, due to the unpredictable way events naturally occur. (Pure) functional languages are notable for being trivially parallelizable, and hard to optimize. A game is HARD to write, and I recommend just doing it in a typical language, before taking on something just as complex (functional programming).

Aug12

comment

How to represent projectiles in video game?Technically, a ray is a start point and a direction. This can be determined WITH a start point and another point, but this is not part of its definition. By definition, rays are infinite, and have no end point.

Why four buttons rather than two?I can't imagine playing Mega Man X with 2 buttons or 6 (in the right-hand thumb location). My thumb is on Y at all times to charge the blaster, and resting on A or B in preparation to Dash or Jump. I don't think I can reliably push more buttons without having to move my thumb.

Jul31

comment

Book on designing game architecture?Everything becoming "hardcoded" isn't necessarily a bad sign -- you may just be following YAGNI/KISS. Adding new features can mean having to refactor your code. That being said, it's always a good idea to plan and design the game first, so that you don't have to rewrite too much.