Skip to content

Instantly share code, notes, and snippets.

@postcasio
Forked from Radnen/personlist.js
Last active December 22, 2015 01:08
Show Gist options
  • Save postcasio/6394043 to your computer and use it in GitHub Desktop.
Save postcasio/6394043 to your computer and use it in GitHub Desktop.
(function(gpl, dp, cp, cm, me) {
var dirty = true, list = [];
GetPersonList = function() {
if (dirty) {
list = gpl();
dirty = false;
}
return list;
}
DestroyPerson = function(name) {
dirty = true;
dp(name);
}
CreatePerson = function(name, ss, die) {
dirty = true;
cp(name, ss, die);
}
ChangeMap = function(name) {
dirty = true;
cm(name);
}
MapEngine = function(name, fps) {
dirty = true;
me(name, fps);
}
})(GetPersonList, DestroyPerson, CreatePerson, ChangeMap, MapEngine);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment