gdjs.evtsExt__Flash__Flash = gdjs.evtsExt__Flash__Flash || {}; /** * Behavior generated from Flash visibility (blink) */ gdjs.evtsExt__Flash__Flash.Flash = class Flash extends gdjs.RuntimeBehavior { constructor(instanceContainer, behaviorData, owner) { super(instanceContainer, behaviorData, owner); this._runtimeScene = instanceContainer; this._onceTriggers = new gdjs.OnceTriggers(); this._behaviorData = {}; this._sharedData = gdjs.evtsExt__Flash__Flash.Flash.getSharedData( instanceContainer, behaviorData.name ); this._behaviorData.HalfPeriodTime = behaviorData.HalfPeriodTime !== undefined ? behaviorData.HalfPeriodTime : Number("0.1") || 0; this._behaviorData.IsFlashing = false; this._behaviorData.FlashDuration = Number("0") || 0; } // Hot-reload: updateFromBehaviorData(oldBehaviorData, newBehaviorData) { if (oldBehaviorData.HalfPeriodTime !== newBehaviorData.HalfPeriodTime) this._behaviorData.HalfPeriodTime = newBehaviorData.HalfPeriodTime; if (oldBehaviorData.IsFlashing !== newBehaviorData.IsFlashing) this._behaviorData.IsFlashing = newBehaviorData.IsFlashing; if (oldBehaviorData.FlashDuration !== newBehaviorData.FlashDuration) this._behaviorData.FlashDuration = newBehaviorData.FlashDuration; return true; } // Properties: _getHalfPeriodTime() { return this._behaviorData.HalfPeriodTime !== undefined ? this._behaviorData.HalfPeriodTime : Number("0.1") || 0; } _setHalfPeriodTime(newValue) { this._behaviorData.HalfPeriodTime = newValue; } _getIsFlashing() { return this._behaviorData.IsFlashing !== undefined ? this._behaviorData.IsFlashing : false; } _setIsFlashing(newValue) { this._behaviorData.IsFlashing = newValue; } _toggleIsFlashing() { this._setIsFlashing(!this._getIsFlashing()); } _getFlashDuration() { return this._behaviorData.FlashDuration !== undefined ? this._behaviorData.FlashDuration : Number("0") || 0; } _setFlashDuration(newValue) { this._behaviorData.FlashDuration = newValue; } } /** * Shared data generated from Flash visibility (blink) */ gdjs.evtsExt__Flash__Flash.Flash.SharedData = class FlashSharedData { constructor(sharedData) { } // Shared properties: } gdjs.evtsExt__Flash__Flash.Flash.getSharedData = function(instanceContainer, behaviorName) { if (!instanceContainer._Flash_FlashSharedData) { const initialData = instanceContainer.getInitialSharedDataForBehavior( behaviorName ); instanceContainer._Flash_FlashSharedData = new gdjs.evtsExt__Flash__Flash.Flash.SharedData( initialData ); } return instanceContainer._Flash_FlashSharedData; } // Methods: gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext = {}; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1= []; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2= []; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects3= []; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.mapOfGDgdjs_9546evtsExt_9595_9595Flash_9595_9595Flash_9546Flash_9546prototype_9546doStepPreEventsContext_9546GDObjectObjects2Objects = Hashtable.newFrom({"Object": gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2}); gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.eventsList0 = function(runtimeScene, eventsFunctionContext) { { gdjs.copyArray(gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1, gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2); let isConditionTrue_0 = false; isConditionTrue_0 = false; for (var i = 0, k = 0, l = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2.length;i (gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2[i].getBehavior(eventsFunctionContext.getBehaviorName("Behavior"))._getHalfPeriodTime()) ) { isConditionTrue_0 = true; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2[k] = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2[i]; ++k; } } gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2.length = k; if (isConditionTrue_0) { /* Reuse gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2 */ {gdjs.evtsExt__Flash__ToggleVisibility.func(runtimeScene, gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.mapOfGDgdjs_9546evtsExt_9595_9595Flash_9595_9595Flash_9546Flash_9546prototype_9546doStepPreEventsContext_9546GDObjectObjects2Objects, (typeof eventsFunctionContext !== 'undefined' ? eventsFunctionContext : undefined)); }{for(var i = 0, len = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2.length ;i < len;++i) { gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects2[i].resetTimer("Flash_Visibility_Timer"); } }} } };gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.eventsList1 = function(runtimeScene, eventsFunctionContext) { { /* Reuse gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1 */ let isConditionTrue_0 = false; isConditionTrue_0 = false; for (var i = 0, k = 0, l = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1.length;i 0 ) { isConditionTrue_0 = true; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1[k] = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1[i]; ++k; } } gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1.length = k; if (isConditionTrue_0) { isConditionTrue_0 = false; for (var i = 0, k = 0, l = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1.length;i (gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1[i].getBehavior(eventsFunctionContext.getBehaviorName("Behavior"))._getFlashDuration()) ) { isConditionTrue_0 = true; gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1[k] = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1[i]; ++k; } } gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1.length = k; } if (isConditionTrue_0) { /* Reuse gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1 */ {for(var i = 0, len = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1.length ;i < len;++i) { gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1[i].getBehavior(eventsFunctionContext.getBehaviorName("Behavior")).Stop((typeof eventsFunctionContext !== 'undefined' ? eventsFunctionContext : undefined)); } }} } };gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.eventsList2 = function(runtimeScene, eventsFunctionContext) { { gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.eventsList0(runtimeScene, eventsFunctionContext); } { gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.eventsList1(runtimeScene, eventsFunctionContext); } };gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.eventsList3 = function(runtimeScene, eventsFunctionContext) { { gdjs.copyArray(eventsFunctionContext.getObjects("Object"), gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1); let isConditionTrue_0 = false; isConditionTrue_0 = false; for (var i = 0, k = 0, l = gdjs.evtsExt__Flash__Flash.Flash.prototype.doStepPreEventsContext.GDObjectObjects1.length;i