mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 09:41:24 +01:00
resources IIFE module
This commit is contained in:
parent
49ee2fcf7a
commit
fe421bcd0d
1 changed files with 3 additions and 12 deletions
|
|
@ -1,15 +1,6 @@
|
||||||
(function (global, factory) {
|
'use strict';
|
||||||
typeof exports === 'object' && typeof module !== 'undefined' ? (module.exports = factory()) : typeof define === 'function' && define.amd ? define(factory) : (global.Resources = factory());
|
|
||||||
})(this, function () {
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
// apply logic on heightmap edit
|
|
||||||
// apply logic on burgs regeneration
|
|
||||||
// apply logic on population recalculation
|
|
||||||
// apply logic on save
|
|
||||||
// apply logic on load
|
|
||||||
|
|
||||||
|
window.Resources = (function () {
|
||||||
let cells, cellId;
|
let cells, cellId;
|
||||||
|
|
||||||
const getDefault = function () {
|
const getDefault = function () {
|
||||||
|
|
@ -144,4 +135,4 @@
|
||||||
const get = (i) => pack.resources.find((resource) => resource.i === i);
|
const get = (i) => pack.resources.find((resource) => resource.i === i);
|
||||||
|
|
||||||
return {generate, getDefault, defaultModels, methods, getStroke, get};
|
return {generate, getDefault, defaultModels, methods, getStroke, get};
|
||||||
});
|
})();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue