Iterative Functional Reactive Programming with the Nu Game Engine: An Exp Report

2 points by DrDimension ↗ HN
This is an experience report on the design and usage of the Nu Game Engine, a purely-functional 2D game engine written in F# -

http://goo.gl/PRHqOp

Original link here -

https://github.com/bryanedds/FPWorks/blob/master/Nu/Documentation/Iterative%20Functional%20Reactive%20Programming%20with%20the%20Nu%20Game%20Engine.pdf?raw=true

Synopsis

The Nu Game Engine certainly qualifies as 'functional reactive' in that - 1) it is reactive in that it uses user-defined events to derive successive simulation states. 2) it is functional in that is uses pure functions everywhere, even in the event system.

However, I cannot describe it as the typical first-order or higher-order FRP system since it uses neither continuous nor discrete functions explicitly parameterized with time. Instead it uses a classically-iterative approach to advancing game states that is akin to the imperative tick-based style, but implemented with pure functions.

Thus, I gave it the name of 'Iterative FRP'. It's a purely-functional half-step between classic imperative game programming and first / higher-order FRP systems. This document discusses the major plusses and minuses to using this 'iterative' FRP style.

0 comments

[ 2.6 ms ] story [ 7.7 ms ] thread

No comments yet.