define("smashThePigScaterSymbols", ["viewBuilderApi", "smashThePigWinAnimatorPort", "componentmodelComponentApi", "clientkernelLoaderApi", "slotModelApi", "displayEngineApi", "clientkernelTestableApi", "smashThePigScaterSymbolsDeclaration", "gameLayoutApi", "clientkernelEventbusApi", "clientkernelModulesApi"],
    function(viewBuilderApi, smashThePigWinAnimatorPort, componentmodelComponentApi, clientkernelLoaderApi, slotModelApi, displayEngineApi, clientkernelTestableApi, smashThePigScaterSymbolsDeclaration, gameLayoutApi, clientkernelEventbusApi, clientkernelModulesApi) {
        "use strict";

        function $iterator(o) {
            if (o instanceof Array) return function() {
                return {
                    cur: 0,
                    arr: o,
                    hasNext: function() {
                        return this.cur < this.arr.length;
                    },
                    next: function() {
                        return this.arr[this.cur++];
                    }
                };
            };
            return typeof(o.iterator) == 'function' ? $bind(o, o.iterator) : o.iterator;
        };;
        var $fid = 0;

        function $bind(o, m) {
            if (m == null) return null;
            if (m.__id__ == null) m.__id__ = $fid++;
            var f;
            if (o.hx__closures__ == null) o.hx__closures__ = {};
            else f = o.hx__closures__[m.__id__];
            if (f == null) {
                f = function() {
                    return f.method.apply(f.scope, arguments);
                };
                f.scope = o;
                f.method = m;
                o.hx__closures__[m.__id__] = f;
            }
            return f;
        };
        var $_;
        var $estr = function() {
            return _hcmn_.js_Boot.__string_rec(this, '');
        };
        if (typeof haxe == 'undefined') {
            var haxe = {};
        };

        haxe.IMap = function() {}
        haxe.IMap.prototype = {

            get: function(k) {
                return {
                    arguments: ["*"],
                    returns: "null"
                };
            },
            keys: function() {
                return {
                    arguments: [],
                    returns: "null"
                };
            }
        };
        haxe.Log = function() {};
        haxe.Log.__name__ = ["haxe", "Log"];
        haxe.Log.trace = function(v, infos) {
            _hcmn_.js_Boot.__trace(v, infos);
        };
        haxe.Log.prototype.__class__ = haxe.Log;
        if (!haxe.ds) {
            haxe.ds = {};
        };
        haxe.ds.BalancedTree = function() {};
        haxe.ds.BalancedTree.__name__ = ["haxe", "ds", "BalancedTree"];
        haxe.ds.BalancedTree.prototype.root = null;
        haxe.ds.BalancedTree.prototype.set = function(key, value) {
            this.root = this.setLoop(key, value, this.root);
        };
        haxe.ds.BalancedTree.prototype.get = function(key) {
            var node = this.root;
            while (node != null) {
                var c = this.compare(key, node.key);
                if (c == 0) return node.value;
                if (c < 0) node = node.left;
                else node = node.right;
            }
            return null;
        };
        haxe.ds.BalancedTree.prototype.keys = function() {
            var ret = [];
            this.keysLoop(this.root, ret);
            return _hcmn_.HxOverrides.iter(ret);
        };
        haxe.ds.BalancedTree.prototype.setLoop = function(k, v, node) {
            if (node == null) return new haxe.ds.TreeNode(null, k, v, null);
            var c = this.compare(k, node.key);
            if (c == 0) return new haxe.ds.TreeNode(node.left, k, v, node.right, node == null ? 0 : node._height);
            else if (c < 0) {
                var nl = this.setLoop(k, v, node.left);
                return this.balance(nl, node.key, node.value, node.right);
            } else {
                var nr = this.setLoop(k, v, node.right);
                return this.balance(node.left, node.key, node.value, nr);
            }
        };
        haxe.ds.BalancedTree.prototype.keysLoop = function(node, acc) {
            if (node != null) {
                this.keysLoop(node.left, acc);
                acc.push(node.key);
                this.keysLoop(node.right, acc);
            }
        };
        haxe.ds.BalancedTree.prototype.balance = function(l, k, v, r) {
            var hl;
            if (l == null) hl = 0;
            else hl = l._height;
            var hr;
            if (r == null) hr = 0;
            else hr = r._height;
            if (hl > hr + 2) {
                if ((function($this) {
                        var $r;
                        var _this = l.left;
                        $r = _this == null ? 0 : _this._height;
                        return $r;
                    }(this)) >= (function($this) {
                        var $r;
                        var _this1 = l.right;
                        $r = _this1 == null ? 0 : _this1._height;
                        return $r;
                    }(this))) return new haxe.ds.TreeNode(l.left, l.key, l.value, new haxe.ds.TreeNode(l.right, k, v, r));
                else return new haxe.ds.TreeNode(new haxe.ds.TreeNode(l.left, l.key, l.value, l.right.left), l.right.key, l.right.value, new haxe.ds.TreeNode(l.right.right, k, v, r));
            } else if (hr > hl + 2) {
                if ((function($this) {
                        var $r;
                        var _this2 = r.right;
                        $r = _this2 == null ? 0 : _this2._height;
                        return $r;
                    }(this)) > (function($this) {
                        var $r;
                        var _this3 = r.left;
                        $r = _this3 == null ? 0 : _this3._height;
                        return $r;
                    }(this))) return new haxe.ds.TreeNode(new haxe.ds.TreeNode(l, k, v, r.left), r.key, r.value, r.right);
                else return new haxe.ds.TreeNode(new haxe.ds.TreeNode(l, k, v, r.left.left), r.left.key, r.left.value, new haxe.ds.TreeNode(r.left.right, r.key, r.value, r.right));
            } else return new haxe.ds.TreeNode(l, k, v, r, (hl > hr ? hl : hr) + 1);
        };
        haxe.ds.BalancedTree.prototype.compare = function(k1, k2) {
            return _hcmn_.Reflect.compare(k1, k2);
        };
        haxe.ds.BalancedTree.prototype.__class__ = haxe.ds.BalancedTree;
        haxe.ds.TreeNode = function(l, k, v, r, h) {
            if (h == null) h = -1;
            this.left = l;
            this.key = k;
            this.value = v;
            this.right = r;
            if (h == -1) this._height = ((function($this) {
                var $r;
                var _this = $this.left;
                $r = _this == null ? 0 : _this._height;
                return $r;
            }(this)) > (function($this) {
                var $r;
                var _this1 = $this.right;
                $r = _this1 == null ? 0 : _this1._height;
                return $r;
            }(this)) ? (function($this) {
                var $r;
                var _this2 = $this.left;
                $r = _this2 == null ? 0 : _this2._height;
                return $r;
            }(this)) : (function($this) {
                var $r;
                var _this3 = $this.right;
                $r = _this3 == null ? 0 : _this3._height;
                return $r;
            }(this))) + 1;
            else this._height = h;
        };
        haxe.ds.TreeNode.__name__ = ["haxe", "ds", "TreeNode"];
        haxe.ds.TreeNode.prototype.left = null;
        haxe.ds.TreeNode.prototype.right = null;
        haxe.ds.TreeNode.prototype.key = null;
        haxe.ds.TreeNode.prototype.value = null;
        haxe.ds.TreeNode.prototype._height = null;
        haxe.ds.TreeNode.prototype.__class__ = haxe.ds.TreeNode;
        haxe.ds.EnumValueMap = function() {
            haxe.ds.BalancedTree.call(this);
        };
        haxe.ds.EnumValueMap.__interfaces__ = [haxe.IMap];
        haxe.ds.EnumValueMap.__name__ = ["haxe", "ds", "EnumValueMap"];
        haxe.ds.EnumValueMap.__super__ = haxe.ds.BalancedTree;
        for (var k in haxe.ds.BalancedTree.prototype) haxe.ds.EnumValueMap.prototype[k] = haxe.ds.BalancedTree.prototype[k];
        haxe.ds.EnumValueMap.prototype.compare = function(k1, k2) {
            var d = k1[1] - k2[1];
            if (d != 0) return d;
            var p1 = k1.slice(2);
            var p2 = k2.slice(2);
            if (p1.length == 0 && p2.length == 0) return 0;
            return this.compareArgs(p1, p2);
        };
        haxe.ds.EnumValueMap.prototype.compareArgs = function(a1, a2) {
            var ld = a1.length - a2.length;
            if (ld != 0) return ld;
            var _g1 = 0;
            var _g = a1.length;
            while (_g1 < _g) {
                var i = _g1++;
                var d = this.compareArg(a1[i], a2[i]);
                if (d != 0) return d;
            }
            return 0;
        };
        haxe.ds.EnumValueMap.prototype.compareArg = function(v1, v2) {
            if (_hcmn_.Reflect.isEnumValue(v1) && _hcmn_.Reflect.isEnumValue(v2)) return this.compare(v1, v2);
            else if ((v1 instanceof Array) && v1.__enum__ == null && ((v2 instanceof Array) && v2.__enum__ == null)) return this.compareArgs(v1, v2);
            else return _hcmn_.Reflect.compare(v1, v2);
        };
        haxe.ds.EnumValueMap.prototype.__class__ = haxe.ds.EnumValueMap;
        if (typeof js == 'undefined') {
            var js = {};
        };
        if (!js._Boot) {
            js._Boot = {};
        };
        js._Boot.HaxeError = function(val) {
            Error.call(this);
            this.val = val;
            this.message = String(val);
            if (Error.captureStackTrace) Error.captureStackTrace(this, js._Boot.HaxeError);
        };
        js._Boot.HaxeError.__name__ = ["js", "_Boot", "HaxeError"];
        js._Boot.HaxeError.__super__ = Error;
        for (var k in Error.prototype) js._Boot.HaxeError.prototype[k] = Error.prototype[k];
        js._Boot.HaxeError.prototype.val = null;
        js._Boot.HaxeError.prototype.__class__ = js._Boot.HaxeError;
        if (typeof smashThePigScaterSymbols == 'undefined') {
            var smashThePigScaterSymbols = {};
        };
        smashThePigScaterSymbols.Activator = function(context) {};
        smashThePigScaterSymbols.Activator = ck_implements(smashThePigScaterSymbols.Activator, clientkernelModulesApi.IModuleActivator);
        smashThePigScaterSymbols.Activator.__interfaces__ = [clientkernelModulesApi.IModuleActivator];
        smashThePigScaterSymbols.Activator.__name__ = ["smashThePigScaterSymbols", "Activator"];
        smashThePigScaterSymbols.Activator.prototype.start = function(context) {
            context.getServiceTracker([displayEngineApi.IDisplayProvider, clientkernelTestableApi.ITestable, viewBuilderApi.IViewBuilderFactory]).then(function(context1) {
                smashThePigScaterSymbols.ExternalService.initialize(context1);
                var factory = context1.getAnyService(viewBuilderApi.IViewBuilderFactory, null);
                smashThePigScaterSymbols.ExternalService.viewBuilderFactory = factory;
                context1.registerService(new smashThePigScaterSymbols.ScaterSymbolsFactory(factory), smashThePigScaterSymbolsDeclaration.ScaterSymbolsDeclaration, null);
            });
        };
        smashThePigScaterSymbols.Activator.prototype.stop = function(context) {};
        smashThePigScaterSymbols.Activator.main = function() {};
        smashThePigScaterSymbols.Activator.prototype.__class__ = smashThePigScaterSymbols.Activator;

        smashThePigScaterSymbols.IScater = function() {}
        smashThePigScaterSymbols.IScater.prototype = {

            getDisplayObject: function() {
                return {
                    arguments: [],
                    returns: "*"
                };
            },
            setVisible: function(visible) {
                return {
                    arguments: ["boolean"],
                    returns: "void"
                };
            },
            getContainerComponent: function(component) {
                return {
                    arguments: ["*"],
                    returns: "*"
                };
            }
        };

        smashThePigScaterSymbols.IScatterSymbols = function() {}
        smashThePigScaterSymbols.IScatterSymbols.prototype = {

            showRegular: function(scatterWins, loop) {
                return {
                    arguments: ["array", "boolean"],
                    returns: "void"
                };
            },
            showLanding: function(reelPicture, reelStopped) {
                return {
                    arguments: ["array", "number"],
                    returns: "void"
                };
            },
            hide: function() {
                return {
                    arguments: [],
                    returns: "void"
                };
            },
            stopScaterLanding: function() {
                return {
                    arguments: [],
                    returns: "void"
                };
            }
        };
        smashThePigScaterSymbols.ExternalService = function() {};
        smashThePigScaterSymbols.ExternalService.__name__ = ["smashThePigScaterSymbols", "ExternalService"];
        smashThePigScaterSymbols.ExternalService.displayProvider = null;
        smashThePigScaterSymbols.ExternalService.assetRegistry = null;
        smashThePigScaterSymbols.ExternalService.testableLogger = null;
        smashThePigScaterSymbols.ExternalService.viewBuilderFactory = null;
        smashThePigScaterSymbols.ExternalService.initialize = function(context) {
            smashThePigScaterSymbols.ExternalService.displayProvider = context.getAnyService(displayEngineApi.IDisplayProvider, null);
            smashThePigScaterSymbols.ExternalService.assetRegistry = context.getAnyService(clientkernelLoaderApi.IAssetRegistry, null);
            var testable = context.getAnyService(clientkernelTestableApi.ITestable, null);
            smashThePigScaterSymbols.ExternalService.testableLogger = testable.getLogger(context);
        };
        smashThePigScaterSymbols.ExternalService.loadConfig = function(config_id, configCallback) {
            smashThePigScaterSymbols.ExternalService.assetRegistry.getAsset(config_id).getContent().then(function(data) {
                configCallback(data);
            });
        };
        smashThePigScaterSymbols.ExternalService.prototype.__class__ = smashThePigScaterSymbols.ExternalService;
        smashThePigScaterSymbols.ScaterSymbolsApplication = function(context, factory) {
            this.context = context;
            this.layoutPort = context.getUsedPort(gameLayoutApi.IGameLayoutPort);
            this.factory = factory;
            this.winLinesPort = context.getUsedPort(smashThePigWinAnimatorPort.IWinAnimatorPort);
            this.baseEvents = new smashThePigScaterSymbols.BaseEvents();
            this.components = new haxe.ds.EnumValueMap();
            this.layoutPort.getUpdateComponentLayout().subscribe($bind(this, this.updateLayout));
            this.controller = new smashThePigScaterSymbols.ScaterSymbolsController(this, this.layoutPort);
            new smashThePigScaterSymbols.ScaterSymbolModel($bind(this, this.modelInitialised));
            this.winLinesPort.setupWinAnimatorComponents().subscribe($bind(this, this.setupSubComponents));
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication = ck_implements(smashThePigScaterSymbols.ScaterSymbolsApplication, smashThePigScaterSymbols.IScater);
        smashThePigScaterSymbols.ScaterSymbolsApplication.__interfaces__ = [smashThePigScaterSymbols.IScater];
        smashThePigScaterSymbols.ScaterSymbolsApplication.__name__ = ["smashThePigScaterSymbols", "ScaterSymbolsApplication"];
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.components = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.factory = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.controller = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.winAnimationAssets = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.view = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.layerContainers = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.winLinesPort = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.context = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.baseEvents = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.layoutPayload = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.layoutPort = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.assetsLoaded = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.vba = null;
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.setupSubComponents = function(e) {
            smashThePigScaterSymbols.ScaterSymbolModel.setupConfiguration(e.getPayload());
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.modelInitialised = function() {
            this.vba = smashThePigScaterSymbols.ScaterSymbolModel.vba;
            this.assetsLoaded = smashThePigScaterSymbols.ScaterSymbolModel.assetsLoaded;
            this.initialize();
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.updateLayout = function(e) {
            this.layoutPayload = e.getPayload();
            if (!smashThePigScaterSymbols.ScaterSymbolModel.initialised) this.initialize();
            else this.controller.updateLayout(this.layoutPayload, this.context.getInstance());
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.initialize = function() {
            if (this.assetsLoaded && this.layoutPayload != null) {
                this.view = this.factory.createView(this.vba);
                this.view.show();
                this.registerAllComponents();
                this.controller.init();
                this.controller.updateLayout(this.layoutPayload, this.context.getInstance());
                smashThePigScaterSymbols.ScaterSymbolModel.initialised = true;
            }
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.registerAllComponents = function() {
            this.layerContainers = this.view.getChildComponents();
            var $it0 = this.layerContainers.keys();
            while ($it0.hasNext()) {
                var layerId = $it0.next();
                var constructorIndex;
                var _this = _hcmn_.Type.getEnumConstructs(smashThePigScaterSymbols.ComponentsEnum);
                constructorIndex = _hcmn_.HxOverrides.indexOf(_this, layerId, 0);
                if (constructorIndex < 0) continue;
                var componentEnum = _hcmn_.Type.createEnum(smashThePigScaterSymbols.ComponentsEnum, layerId, null);
                if (!this.registerComponent(componentEnum, layerId)) continue;
            }
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.registerComponent = function(componentEnum, layerId) {
            switch (componentEnum[1]) {
                case 1:
                    this.registerContainerComponent(smashThePigScaterSymbols.ComponentsEnum.SCATTER_SYMBOLS, layerId, smashThePigScaterSymbols.ScatterSymbols);
                    break;
                default:
                    return false;
            }
            return true;
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.registerContainerComponent = function(component, layerId, componentClass) {
            var container = this.view.getComponentById(component[0]);
            if (container == null) return;
            if (componentClass != null) {
                var specificComponent = _hcmn_.Type.createInstance(componentClass, [container, this.baseEvents]);
                this.components.set(component, specificComponent);
            } else this.components.set(component, container);
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.setVisible = function(visible) {
            this.getDisplayObject().setVisible(visible);
            var $it0 = (function($this) {
                var $r;
                var this1 = $this.view.getChildComponents();
                $r = this1.keys();
                return $r;
            }(this));
            while ($it0.hasNext()) {
                var key = $it0.next();
                var container = this.view.getComponentById(key);
                container.getDisplayObject().setVisible(visible);
            }
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.getDisplayObject = function() {
            return this.view.getDisplayObject();
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.getSkatterSymbols = function() {
            return this.components.get(smashThePigScaterSymbols.ComponentsEnum.SCATTER_SYMBOLS);
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.getContainerComponent = function(component) {
            return this.components.get(component);
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.getBaseEvent = function(id) {
            return this.baseEvents.getEvent(id);
        };
        smashThePigScaterSymbols.ScaterSymbolsApplication.prototype.__class__ = smashThePigScaterSymbols.ScaterSymbolsApplication;
        smashThePigScaterSymbols.Controller = function(controllerInstance) {
            smashThePigScaterSymbols.Controller._CONTROLLERS.push(controllerInstance);
        };
        smashThePigScaterSymbols.Controller.__name__ = ["smashThePigScaterSymbols", "Controller"];
        smashThePigScaterSymbols.Controller.prototype.sendMessage = function(message) {
            var _g1 = 0;
            var _g = smashThePigScaterSymbols.Controller._CONTROLLERS.length;
            while (_g1 < _g) {
                var i = _g1++;
                var controller = smashThePigScaterSymbols.Controller._CONTROLLERS[i];
                var controllerEvents = controller.getInterests();
                var _g3 = 0;
                var _g2 = controllerEvents.length;
                while (_g3 < _g2) {
                    var m = _g3++;
                    var interestedInMessage = controllerEvents[m];
                    if (interestedInMessage == message._messageName) {
                        controller.processMessage(message);
                        break;
                    }
                }
            }
        };
        smashThePigScaterSymbols.Controller.prototype.getInterests = function() {
            return [];
        };
        smashThePigScaterSymbols.Controller.prototype.processMessage = function(message) {};
        smashThePigScaterSymbols.Controller.prototype.__class__ = smashThePigScaterSymbols.Controller;
        smashThePigScaterSymbols.ScaterSymbolsController = function(winAnimations, layoutPort) {
            this.scaterAnimations = winAnimations;
            this.layoutPort = layoutPort;
            smashThePigScaterSymbols.Controller.call(this, this);
        };
        smashThePigScaterSymbols.ScaterSymbolsController.__name__ = ["smashThePigScaterSymbols", "ScaterSymbolsController"];
        smashThePigScaterSymbols.ScaterSymbolsController.__super__ = smashThePigScaterSymbols.Controller;
        for (var k in smashThePigScaterSymbols.Controller.prototype) smashThePigScaterSymbols.ScaterSymbolsController.prototype[k] = smashThePigScaterSymbols.Controller.prototype[k];
        smashThePigScaterSymbols.ScaterSymbolsController.prototype.scaterAnimations = null;
        smashThePigScaterSymbols.ScaterSymbolsController.prototype.layoutPort = null;
        smashThePigScaterSymbols.ScaterSymbolsController.prototype.init = function() {
            new smashThePigScaterSymbols.LayoutController(this.scaterAnimations);
            new smashThePigScaterSymbols.ScaterSymbolsPortController(this.scaterAnimations.winLinesPort, this.layoutPort, this.scaterAnimations);
        };
        smashThePigScaterSymbols.ScaterSymbolsController.prototype.updateLayout = function(layoutPayload, instance) {
            this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("updateLayout", layoutPayload));
            this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("updateUpdatedComponentsPort", instance));
        };
        smashThePigScaterSymbols.ScaterSymbolsController.prototype.__class__ = smashThePigScaterSymbols.ScaterSymbolsController;
        smashThePigScaterSymbols.ScaterSymbolsFactory = function(vbf) {
            this.vbf = vbf;
        };
        smashThePigScaterSymbols.ScaterSymbolsFactory = ck_implements(smashThePigScaterSymbols.ScaterSymbolsFactory, clientkernelModulesApi.IService);
        smashThePigScaterSymbols.ScaterSymbolsFactory = ck_implements(smashThePigScaterSymbols.ScaterSymbolsFactory, componentmodelComponentApi.IComponentFactory);
        smashThePigScaterSymbols.ScaterSymbolsFactory.__interfaces__ = [clientkernelModulesApi.IService, componentmodelComponentApi.IComponentFactory];
        smashThePigScaterSymbols.ScaterSymbolsFactory.__name__ = ["smashThePigScaterSymbols", "ScaterSymbolsFactory"];
        smashThePigScaterSymbols.ScaterSymbolsFactory.prototype.vbf = null;
        smashThePigScaterSymbols.ScaterSymbolsFactory.prototype.getComponentDeclaration = function() {
            return smashThePigScaterSymbolsDeclaration.ScaterSymbolsDeclaration;
        };
        smashThePigScaterSymbols.ScaterSymbolsFactory.prototype.createComponent = function(context) {
            var _winlines = new smashThePigScaterSymbols.ScaterSymbolsApplication(context, this.vbf);
        };
        smashThePigScaterSymbols.ScaterSymbolsFactory.prototype.__class__ = smashThePigScaterSymbols.ScaterSymbolsFactory;
        smashThePigScaterSymbols.ScatterSymbols = function(container, baseEvents) {
            this.totalVisibleSymbols = 0;
            this.reelsNum = smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.numberOfColums;
            this.cellsNum = smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.numberOfRows;
            this.symbolOffset = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.symbolOffset;
            this.symbolName = smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.scaterSymbolName;
            this.yOffset = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.yOffset;
            this.xOffset = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.xOffset;
            this.verticalGap = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.marginTop;
            this.horisontalGap = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.marginLeft;
            this.symbolHeight = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.height;
            this.symbolWidth = smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration.width;
            haxe.Log.trace("[LN] ScatterSymbols:init", {
                fileName: "ScatterSymbols.hx",
                lineNumber: 45,
                className: "smashthepig.components.scatersymbols.component.imp.components.ScatterSymbols",
                methodName: "new"
            });
            this.baseEvents = baseEvents;
            this.container = container;
            this.symbolsAssets = smashThePigScaterSymbols.ExternalService.loadedAssets;
            container.show();
        };
        smashThePigScaterSymbols.ScatterSymbols = ck_implements(smashThePigScaterSymbols.ScatterSymbols, smashThePigScaterSymbols.IScatterSymbols);
        smashThePigScaterSymbols.ScatterSymbols.__interfaces__ = [smashThePigScaterSymbols.IScatterSymbols];
        smashThePigScaterSymbols.ScatterSymbols.__name__ = ["smashThePigScaterSymbols", "ScatterSymbols"];
        smashThePigScaterSymbols.ScatterSymbols.prototype.container = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.symbolWidth = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.symbolHeight = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.horisontalGap = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.verticalGap = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.xOffset = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.yOffset = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.symbolName = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.symbolOffset = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.cellsNum = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.reelsNum = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.symbolsAssets = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.totalVisibleSymbols = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.baseEvents = null;
        smashThePigScaterSymbols.ScatterSymbols.prototype.showLanding = function(reelPicture, reelStopped) {
            haxe.Log.trace("[LN] ScatterSymbols:.showLanding: ", {
                fileName: "ScatterSymbols.hx",
                lineNumber: 53,
                className: "smashthepig.components.scatersymbols.component.imp.components.ScatterSymbols",
                methodName: "showLanding",
                customParams: [reelPicture, reelStopped]
            });
        };
        smashThePigScaterSymbols.ScatterSymbols.prototype.showRegular = function(scatterWins, loop) {
            smashThePigScaterSymbols.ExternalService.testableLogger.info("scatterWins", {
                scatterWins: scatterWins
            });
            haxe.Log.trace("[LN] ScatterSymbols:showRegular: ", {
                fileName: "ScatterSymbols.hx",
                lineNumber: 59,
                className: "smashthepig.components.scatersymbols.component.imp.components.ScatterSymbols",
                methodName: "showRegular",
                customParams: [scatterWins, " looped: ", loop]
            });
            if (scatterWins != null && scatterWins.length > 0) {
                var wins = scatterWins.length;
                var _g = 0;
                while (_g < wins) {
                    var i = _g++;
                    var columns = scatterWins[i].winPath.reelsInfo.length;
                    var _g1 = 0;
                    while (_g1 < columns) {
                        var col = _g1++;
                        var rows = scatterWins[i].winPath.reelsInfo[col].length;
                        var _g3 = 0;
                        var _g2 = this.cellsNum;
                        while (_g3 < _g2) {
                            var row = _g3++;
                            var winId = scatterWins[i].winPath.reelsInfo[col][row + this.symbolOffset];
                            if (winId == 1) {
                                var id = this.symbolName + "_CONTAINER" + "_" + row + "_" + col;
                                if (this.container.getComponentById(id) == null) {
                                    var vbAssetId = this.symbolName + "_" + scatterWins[i].winningSymbol + "_VB";
                                    var vbAsset = this.symbolsAssets.get(vbAssetId);
                                    var containerId = this.symbolName + "_" + scatterWins[i].winningSymbol + "_CONTAINER";
                                    var vbAnimView = smashThePigScaterSymbols.ExternalService.viewBuilderFactory.createView(vbAsset);
                                    var symbolContainer = this.container.createContainerFromStoredConfig(containerId);
                                    this.container.addChildComponent(symbolContainer, this.symbolName + "_CONTAINER" + "_" + row + "_" + col);
                                    symbolContainer.setX(this.xOffset + (this.symbolWidth + this.horisontalGap) * col);
                                    symbolContainer.setY(this.yOffset + (this.symbolHeight + this.verticalGap) * row);
                                    symbolContainer.show();
                                    var vbAnimationHolder = vbAnimView.createContainerFromStoredConfig("ANIMATION_HOLDER");
                                    var vbAnimationComponent;
                                    vbAnimationComponent = _hcmn_.js_Boot.__cast(vbAnimationHolder.getComponentById("ANIMATION_CONTENT"), viewBuilderApi.IVBAnimationComponent);
                                    symbolContainer.addChildComponent(vbAnimationHolder, this.symbolName + "VB");
                                    this.totalVisibleSymbols++;
                                    vbAnimationComponent.gotoAndPlay(true, "loop", (function(f, id1) {
                                        return function() {
                                            f(id1);
                                        };
                                    })($bind(this, this.played), this.totalVisibleSymbols), 5);
                                    vbAnimationComponent.addEventListener("evLoopComplete", $bind(this, this.handleAnimationComplete), [vbAnimationComponent, false]);
                                } else {
                                    var vbAnimView1 = this.container.getComponentById(id);
                                    var vbAnimationHolder1 = vbAnimView1.getComponentById(this.symbolName + "VB");
                                    var vbAnimationComponent1;
                                    vbAnimationComponent1 = _hcmn_.js_Boot.__cast(vbAnimationHolder1.getComponentById("ANIMATION_CONTENT"), viewBuilderApi.IVBAnimationComponent);
                                    vbAnimationComponent1.gotoAndPlay(true, "loop", (function(f1, id2) {
                                        return function() {
                                            f1(id2);
                                        };
                                    })($bind(this, this.played), this.totalVisibleSymbols), 5);
                                }
                            }
                        }
                    }
                }
            }
            if (this.totalVisibleSymbols == 0) this.baseEvents.getEvent(smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED).dispatch(null);
        };
        smashThePigScaterSymbols.ScatterSymbols.prototype.handleAnimationComplete = function(evt) {
            var vbAnimation = evt[0];
            var loop = evt[1];
            if (!loop) {
                vbAnimation.removeEventListener("evLoopComplete");
                vbAnimation.stop();
            }
        };
        smashThePigScaterSymbols.ScatterSymbols.prototype.played = function(id) {
            if (id == this.totalVisibleSymbols) this.baseEvents.getEvent(smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED).dispatch(null);
        };
        smashThePigScaterSymbols.ScatterSymbols.prototype.hide = function() {
            haxe.Log.trace("[LN] ScatterSymbols:hide ", {
                fileName: "ScatterSymbols.hx",
                lineNumber: 132,
                className: "smashthepig.components.scatersymbols.component.imp.components.ScatterSymbols",
                methodName: "hide"
            });
            var $it0 = (function($this) {
                var $r;
                var this1 = $this.container.getChildComponents();
                $r = this1.keys();
                return $r;
            }(this));
            while ($it0.hasNext()) {
                var key = $it0.next();
                this.container.disposeChildComponent(key);
            }
            this.totalVisibleSymbols = 0;
        };
        smashThePigScaterSymbols.ScatterSymbols.prototype.stopScaterLanding = function() {
            haxe.Log.trace("[LN] ScatterSymbols:stopScaterLanding: ", {
                fileName: "ScatterSymbols.hx",
                lineNumber: 141,
                className: "smashthepig.components.scatersymbols.component.imp.components.ScatterSymbols",
                methodName: "stopScaterLanding"
            });
        };
        smashThePigScaterSymbols.ScatterSymbols.prototype.__class__ = smashThePigScaterSymbols.ScatterSymbols;
        smashThePigScaterSymbols.LayoutController = function(scaterApplication) {
            this.scaterSymbolsApplication = scaterApplication;
            this.scaterSymbols = this.scaterSymbolsApplication.getSkatterSymbols();
            smashThePigScaterSymbols.Controller.call(this, this);
        };
        smashThePigScaterSymbols.LayoutController.__name__ = ["smashThePigScaterSymbols", "LayoutController"];
        smashThePigScaterSymbols.LayoutController.__super__ = smashThePigScaterSymbols.Controller;
        for (var k in smashThePigScaterSymbols.Controller.prototype) smashThePigScaterSymbols.LayoutController.prototype[k] = smashThePigScaterSymbols.Controller.prototype[k];
        smashThePigScaterSymbols.LayoutController.prototype.scaterSymbols = null;
        smashThePigScaterSymbols.LayoutController.prototype.scaterSymbolsApplication = null;
        smashThePigScaterSymbols.LayoutController.prototype.getInterests = function() {
            return ["handleScaterSymbols", "showScaterLanding", "stopScaterLanding", "hideAll", "setVisible", "updateLayout"];
        };
        smashThePigScaterSymbols.LayoutController.prototype.processMessage = function(message) {
            var _g = message._messageName;
            switch (_g) {
                case "updateLayout":
                    this.updateLayout(message._messageData);
                    break;
                case "handleScaterSymbols":
                    this.handleScaterSymbols(message._messageData);
                    break;
                case "showScaterLanding":
                    this.showScaterLanding(message._messageData);
                    break;
                case "stopScaterLanding":
                    this.stopScaterLanding();
                    break;
                case "hideAll":
                    this.hideAll();
                    break;
                case "setVisible":
                    this.setVisible(message._messageData);
                    break;
            }
        };
        smashThePigScaterSymbols.LayoutController.prototype.stopScaterLanding = function() {};
        smashThePigScaterSymbols.LayoutController.prototype.setVisible = function(messageData) {
            var visible;
            visible = _hcmn_.js_Boot.__cast(messageData, _hcmn_.Bool);
            this.scaterSymbolsApplication.setVisible(visible);
        };
        smashThePigScaterSymbols.LayoutController.prototype.handleScaterSymbols = function(messageData) {
            var handleScaterSymbolsOutcome;
            handleScaterSymbolsOutcome = _hcmn_.js_Boot.__cast(messageData, smashThePigScaterSymbols.HandleScaterSymboslPayload);
            this.scaterSymbols.showRegular(handleScaterSymbolsOutcome.scaterWin, handleScaterSymbolsOutcome.loop);
        };
        smashThePigScaterSymbols.LayoutController.prototype.showScaterLanding = function(messageData) {
            var showScaterLandingPayload;
            showScaterLandingPayload = _hcmn_.js_Boot.__cast(messageData, smashThePigWinAnimatorPort.ShowScaterLandingPayload);
            this.scaterSymbols.showLanding(showScaterLandingPayload.landingSymbols, showScaterLandingPayload.reelStopped);
        };
        smashThePigScaterSymbols.LayoutController.prototype.hideAll = function() {
            this.scaterSymbols.hide();
        };
        smashThePigScaterSymbols.LayoutController.prototype.updateLayout = function(messageData) {
            var layoutPayload;
            layoutPayload = _hcmn_.js_Boot.__cast(messageData, gameLayoutApi.ComponentLayout);
            var $it0 = this.scaterSymbolsApplication.layerContainers.keys();
            while ($it0.hasNext()) {
                var layerId = $it0.next();
                var layerPayload = layoutPayload.containers.get(layerId);
                if (layerPayload == null) continue;
                var stage;
                var this1 = smashThePigScaterSymbols.ExternalService.displayProvider.getStages();
                stage = this1.get(layerPayload.stage);
                var container = this.scaterSymbolsApplication.layerContainers.get(layerId).getDisplayObject();
                try {
                    stage.removeChild(container);
                } catch (e) {
                    if (e instanceof js._Boot.HaxeError) e = e.val;
                    if (_hcmn_.js_Boot.__instanceof(e, Error)) {} else throw (e);
                }
                stage.addChild(container);
                container.setX(layerPayload.left);
                container.setY(layerPayload.top);
                container.setScaleX(layerPayload.width / container.getUserData().viewBuilderW);
                container.setScaleY(layerPayload.height / container.getUserData().viewBuilderH);
                container.setZIndex(layerPayload.zIndex);
            }
        };
        smashThePigScaterSymbols.LayoutController.prototype.__class__ = smashThePigScaterSymbols.LayoutController;
        smashThePigScaterSymbols.ScaterSymbolsPortController = function(winAnimatorPort, layoutPort, winAnimations) {
            this.cellsNum = smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.numberOfRows;
            this.reelsNum = smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.numberOfColums;
            this.winAnimatorPort = winAnimatorPort;
            this.layoutPort = layoutPort;
            winAnimations.getBaseEvent(smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED).add($bind(this, this.handleDisplayReady));
            this.winAnimatorPort.show().subscribe($bind(this, this.handleScaterSymbols));
            this.winAnimatorPort.showScaterLanding().subscribe($bind(this, this.handleLandingSymbols));
            this.winAnimatorPort.hideAll().subscribe($bind(this, this.hideAll));
            this.winAnimatorPort.setSubComponentVisible().subscribe($bind(this, this.handleSetVisible));
            this.winAnimatorPort.stopScaterLanding().subscribe($bind(this, this.handleStopScaterLanding));
            smashThePigScaterSymbols.Controller.call(this, this);
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.__name__ = ["smashThePigScaterSymbols", "ScaterSymbolsPortController"];
        smashThePigScaterSymbols.ScaterSymbolsPortController.__super__ = smashThePigScaterSymbols.Controller;
        for (var k in smashThePigScaterSymbols.Controller.prototype) smashThePigScaterSymbols.ScaterSymbolsPortController.prototype[k] = smashThePigScaterSymbols.Controller.prototype[k];
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.winAnimatorPort = null;
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.reelsNum = null;
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.cellsNum = null;
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.layoutPort = null;
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.handleStopScaterLanding = function(e) {
            this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("stopScaterLanding"));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.handleScaterSymbols = function(e) {
            var showWinAnimationPayload = e.getPayload();
            this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("handleScaterSymbols", new smashThePigScaterSymbols.HandleScaterSymboslPayload(showWinAnimationPayload.allWinningSymbols, showWinAnimationPayload.outcome.scatterWins, showWinAnimationPayload.outcomeOptionsPayload.loop)));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.getInterests = function() {
            return ["updateUpdatedComponentsPort"];
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.processMessage = function(message) {
            var _g = message._messageName;
            switch (_g) {
                case "updateUpdatedComponentsPort":
                    this.updateLayoutUpdatedComponentsPort(message._messageData);
                    break;
            }
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.updateLayoutUpdatedComponentsPort = function(messageData) {
            var instance;
            instance = _hcmn_.js_Boot.__cast(messageData, componentmodelComponentApi.IComponentInstance);
            this.layoutPort.getComponentLayoutUpdated().publish(instance);
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.handleLandingSymbols = function(e) {
            var outcomeOptionsPayload = e.getPayload();
            if (outcomeOptionsPayload != null) {
                if (outcomeOptionsPayload.landingSymbols != null && outcomeOptionsPayload.landingSymbols.length > 0) this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("showScaterLanding", outcomeOptionsPayload));
            }
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.handleSetVisible = function(e) {
            this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("setVisible", e.getPayload()));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.hideAll = function(e) {
            this.sendMessage(new smashThePigScaterSymbols.WinAnimatorMessagePayload("hideAll"));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.handleDisplayReady = function(evt) {
            this.winAnimatorPort.requestDelegation().publish(new smashThePigWinAnimatorPort.RequestDelegationPayload(smashThePigWinAnimatorPort.RequestDelegationPayload.GET_WIN_SYMBOLS_CREATED, null));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.handleCurrentWinLine = function(data) {
            this.winAnimatorPort.requestDelegation().publish(new smashThePigWinAnimatorPort.RequestDelegationPayload(smashThePigWinAnimatorPort.RequestDelegationPayload.GET_CURRENT_WIN, data));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.winLineCycleEnded = function(data) {
            this.winAnimatorPort.requestDelegation().publish(new smashThePigWinAnimatorPort.RequestDelegationPayload(smashThePigWinAnimatorPort.RequestDelegationPayload.GET_WIN_LINES_CYCLE_ANIMATED, null));
        };
        smashThePigScaterSymbols.ScaterSymbolsPortController.prototype.__class__ = smashThePigScaterSymbols.ScaterSymbolsPortController;
        smashThePigScaterSymbols.BaseEventsEnum = {
            __ename__: ["smashThePigScaterSymbols", "BaseEventsEnum"],
            __constructs__: ["WIN_FRAMES_CYCLE_ENDED", "CURRENT_WIN_LINE_SHOWN", "CALLBACK_RECIVED"]
        };
        smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED = ["CALLBACK_RECIVED", 2];
        smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED.toString = $estr;
        smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED.__enum__ = smashThePigScaterSymbols.BaseEventsEnum;
        smashThePigScaterSymbols.BaseEventsEnum.CURRENT_WIN_LINE_SHOWN = ["CURRENT_WIN_LINE_SHOWN", 1];
        smashThePigScaterSymbols.BaseEventsEnum.CURRENT_WIN_LINE_SHOWN.toString = $estr;
        smashThePigScaterSymbols.BaseEventsEnum.CURRENT_WIN_LINE_SHOWN.__enum__ = smashThePigScaterSymbols.BaseEventsEnum;
        smashThePigScaterSymbols.BaseEventsEnum.WIN_FRAMES_CYCLE_ENDED = ["WIN_FRAMES_CYCLE_ENDED", 0];
        smashThePigScaterSymbols.BaseEventsEnum.WIN_FRAMES_CYCLE_ENDED.toString = $estr;
        smashThePigScaterSymbols.BaseEventsEnum.WIN_FRAMES_CYCLE_ENDED.__enum__ = smashThePigScaterSymbols.BaseEventsEnum;
        smashThePigScaterSymbols.ComponentsEnum = {
            __ename__: ["smashThePigScaterSymbols", "ComponentsEnum"],
            __constructs__: ["WIN_FRAMES", "SCATTER_SYMBOLS", "WIN_SYMBOLS", "TOP_SYMBOLS"]
        };
        smashThePigScaterSymbols.ComponentsEnum.TOP_SYMBOLS = ["TOP_SYMBOLS", 3];
        smashThePigScaterSymbols.ComponentsEnum.TOP_SYMBOLS.toString = $estr;
        smashThePigScaterSymbols.ComponentsEnum.TOP_SYMBOLS.__enum__ = smashThePigScaterSymbols.ComponentsEnum;
        smashThePigScaterSymbols.ComponentsEnum.WIN_FRAMES = ["WIN_FRAMES", 0];
        smashThePigScaterSymbols.ComponentsEnum.WIN_FRAMES.toString = $estr;
        smashThePigScaterSymbols.ComponentsEnum.WIN_FRAMES.__enum__ = smashThePigScaterSymbols.ComponentsEnum;
        smashThePigScaterSymbols.ComponentsEnum.SCATTER_SYMBOLS = ["SCATTER_SYMBOLS", 1];
        smashThePigScaterSymbols.ComponentsEnum.SCATTER_SYMBOLS.toString = $estr;
        smashThePigScaterSymbols.ComponentsEnum.SCATTER_SYMBOLS.__enum__ = smashThePigScaterSymbols.ComponentsEnum;
        smashThePigScaterSymbols.ComponentsEnum.WIN_SYMBOLS = ["WIN_SYMBOLS", 2];
        smashThePigScaterSymbols.ComponentsEnum.WIN_SYMBOLS.toString = $estr;
        smashThePigScaterSymbols.ComponentsEnum.WIN_SYMBOLS.__enum__ = smashThePigScaterSymbols.ComponentsEnum;
        smashThePigScaterSymbols.InternalMVCConstants = function() {};
        smashThePigScaterSymbols.InternalMVCConstants.__name__ = ["smashThePigScaterSymbols", "InternalMVCConstants"];
        smashThePigScaterSymbols.InternalMVCConstants.prototype.__class__ = smashThePigScaterSymbols.InternalMVCConstants;
        smashThePigScaterSymbols.BaseEvents = function() {
            this.events = new haxe.ds.EnumValueMap();
            this.registerEvents();
        };
        smashThePigScaterSymbols.BaseEvents.__name__ = ["smashThePigScaterSymbols", "BaseEvents"];
        smashThePigScaterSymbols.BaseEvents.prototype.events = null;
        smashThePigScaterSymbols.BaseEvents.prototype.registerEvents = function() {
            var value = new _hcmn_.msignal_Signal1();
            this.events.set(smashThePigScaterSymbols.BaseEventsEnum.WIN_FRAMES_CYCLE_ENDED, value);
            var value1 = new _hcmn_.msignal_Signal1();
            this.events.set(smashThePigScaterSymbols.BaseEventsEnum.CURRENT_WIN_LINE_SHOWN, value1);
            var value2 = new _hcmn_.msignal_Signal1();
            this.events.set(smashThePigScaterSymbols.BaseEventsEnum.CALLBACK_RECIVED, value2);
        };
        smashThePigScaterSymbols.BaseEvents.prototype.getEvent = function(id) {
            return this.events.get(id);
        };
        smashThePigScaterSymbols.BaseEvents.prototype.__class__ = smashThePigScaterSymbols.BaseEvents;
        smashThePigScaterSymbols.ScaterSymbolModel = function(modelInitialised) {
            smashThePigScaterSymbols.ScaterSymbolModel.callback = modelInitialised;
        };
        smashThePigScaterSymbols.ScaterSymbolModel.__name__ = ["smashThePigScaterSymbols", "ScaterSymbolModel"];
        smashThePigScaterSymbols.ScaterSymbolModel.winFramesConfiguration = null;
        smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration = null;
        smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration = null;
        smashThePigScaterSymbols.ScaterSymbolModel.topSymbosConfiguration = null;
        smashThePigScaterSymbols.ScaterSymbolModel.winSymbosConfiguration = null;
        smashThePigScaterSymbols.ScaterSymbolModel.callback = null;
        smashThePigScaterSymbols.ScaterSymbolModel.setupConfiguration = function(setupConfig) {
            smashThePigScaterSymbols.ScaterSymbolModel.winFramesConfiguration = setupConfig.winFramesConfiguration;
            smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration = setupConfig.winAnimatorGlobalConfiguration;
            smashThePigScaterSymbols.ScaterSymbolModel.scaterSymbolsConfiguration = setupConfig.scaterSymbolsConfiguration;
            smashThePigScaterSymbols.ScaterSymbolModel.topSymbosConfiguration = setupConfig.topSymbolsConfiguration;
            smashThePigScaterSymbols.ScaterSymbolModel.winSymbosConfiguration = setupConfig.winSymbolConfiguration;
            smashThePigScaterSymbols.ScaterSymbolModel.loadVBAssets();
        };
        smashThePigScaterSymbols.ScaterSymbolModel.loadVBAssets = function() {
            smashThePigScaterSymbols.ExternalService.assetRegistry.getAssetsContent(smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.vbAssets).then(function(data) {
                smashThePigScaterSymbols.ExternalService.loadedAssets = data;
                smashThePigScaterSymbols.ScaterSymbolModel.loadMainAssets();
            });
        };
        smashThePigScaterSymbols.ScaterSymbolModel.loadMainAssets = function() {
            smashThePigScaterSymbols.ExternalService.assetRegistry.getAsset(smashThePigScaterSymbols.ScaterSymbolModel.globalConfiguration.mainAssetsId).getContent().then(function(vba) {
                smashThePigScaterSymbols.ScaterSymbolModel.vba = vba;
                smashThePigScaterSymbols.ScaterSymbolModel.assetsLoaded = true;
                smashThePigScaterSymbols.ScaterSymbolModel.callback();
            });
        };
        smashThePigScaterSymbols.ScaterSymbolModel.prototype.__class__ = smashThePigScaterSymbols.ScaterSymbolModel;
        smashThePigScaterSymbols.HandleScaterSymboslPayload = function(allWinningSymbols, scaterWin, loop) {
            this.loop = loop;
            this.scaterWin = scaterWin;
            this.allWinningSymbols = allWinningSymbols;
        };
        smashThePigScaterSymbols.HandleScaterSymboslPayload.__name__ = ["smashThePigScaterSymbols", "HandleScaterSymboslPayload"];
        smashThePigScaterSymbols.HandleScaterSymboslPayload.prototype.loop = null;
        smashThePigScaterSymbols.HandleScaterSymboslPayload.prototype.scaterWin = null;
        smashThePigScaterSymbols.HandleScaterSymboslPayload.prototype.allWinningSymbols = null;
        smashThePigScaterSymbols.HandleScaterSymboslPayload.prototype.__class__ = smashThePigScaterSymbols.HandleScaterSymboslPayload;
        smashThePigScaterSymbols.WinAnimatorMessagePayload = function(messageName, messageData) {
            this._messageName = messageName;
            this._messageData = messageData;
        };
        smashThePigScaterSymbols.WinAnimatorMessagePayload.__name__ = ["smashThePigScaterSymbols", "WinAnimatorMessagePayload"];
        smashThePigScaterSymbols.WinAnimatorMessagePayload.prototype._messageName = null;
        smashThePigScaterSymbols.WinAnimatorMessagePayload.prototype._messageData = null;
        smashThePigScaterSymbols.WinAnimatorMessagePayload.prototype.__class__ = smashThePigScaterSymbols.WinAnimatorMessagePayload;
        smashThePigScaterSymbols.ExternalService.loadedAssets = new _hcmn_.haxe_ds_StringMap();;
        smashThePigScaterSymbols.Controller._CONTROLLERS = [];;
        smashThePigScaterSymbols.InternalMVCConstants.HANDLE_SCATER_SYMBOLS = "handleScaterSymbols";;
        smashThePigScaterSymbols.InternalMVCConstants.SHOW_SCATER_LANDING = "showScaterLanding";;
        smashThePigScaterSymbols.InternalMVCConstants.HIDE_ALL = "hideAll";;
        smashThePigScaterSymbols.InternalMVCConstants.SET_VISIBLE = "setVisible";;
        smashThePigScaterSymbols.InternalMVCConstants.UPDATE_LAYOUT = "updateLayout";;
        smashThePigScaterSymbols.InternalMVCConstants.UPDATE_UPDATED_COMPONENTS_PORT = "updateUpdatedComponentsPort";;
        smashThePigScaterSymbols.InternalMVCConstants.STOP_SCATER_LANDING = "stopScaterLanding";;
        smashThePigScaterSymbols.ScaterSymbolModel.initialised = false;;
        smashThePigScaterSymbols.ScaterSymbolModel.assetsLoaded = false;;
        smashThePigScaterSymbols.ScaterSymbolModel.vba = null;;
        return {
            exports: smashThePigScaterSymbols,
            activator: smashThePigScaterSymbols.Activator
        };
    });
//# sourceURL=smashThePigScaterSymbols.js