GameSoul's Recent Forum Activity

  • Mikal Thanks for reply. It helped a little, but now another error appeared (screenshot below). I also tried to make some localforage script variables global (like a, j), but this error appeared again.

  • Hi everyone! I'm adding modules support to Rex_TimeAwayL plugin and I stuck into a problem. How to make the code in the localforage.js file global?

    I tried to do the same as with Firebase addon (write at the beginning var localforage2=function() {code}, and at the end globalThis.localforage2 = localforage2). But when I preview addon example, project fails to load with the error that localforage2 is not defined.

    In runtime files, functions from localforage look like this:

    localforage2["getItem"](key, callback);

    localforage2["setItem"](key, self.cache[key], onWriteTimer);

    Here is code in localforage.js: pastebin.com/mrQ9H7Kp

  • Added new addons:

    Rex_Firebase_ItemBook

    Rex_SLG_Movement

  • arcadesindo Do you mean Rex_Firebase_ItemBook? Not yet, but I'll port it soon.

  • Hello everybody!

    When I ported the Rex_LookUp plugin to the C3Runtime, I ran into some problems with debugger. In this plugin, the debugger values are generated from two places: from the instanceProto and TestMgrKlassProto functions.

    // Plugin debugger code (C2Runtime)
    // All plugin code: https://github.com/rexrainbow/C2Plugins/blob/master/plugins/rex_lookup/runtime.js
    instanceProto.getDebuggerValues = function (propsections)
    	{
    	 var prop = [];
    	 // show test result
    	 this.tests.getDebuggerValues(prop);
    
    	 // show property	 
    	 prop.push({"name": "Property", "value": "Value"});
    	 for (var n in this.props)
    	 {
    	 prop.push({"name": n, "value": this.props[n]});
    	 }	 
    	 
    		propsections.push({
    			"title": this.type.name,
    			"properties": prop
    		});
    	};
    	//
    TestsMgrKlassProto.getDebuggerValues = function (propsections)
    	{
    	 // show test result
    	 propsections.push({"name": "Test", "value": "Result"});
    	 
     var i, cnt=this.tests.length;	
     var info; 
     for (i=0; i<cnt; i++)
     {
     info = this.tests[i].extra;
     propsections.push({"name": info["name"], "value": info["result"]});
     } 
    	};

    I tried to do the same thing in C3Runtime (implement instanceProto functions in c3runtime/instance.js, and TestMgrKlassProto in c3runtime/plugin.js):

    // c3runtime/instance.js debugger code
    // Full version: https://pastebin.com/DJ9YqbFn
    GetDebuggerProperties()
    		{
    			globalThis.prop = [];
    			// show test result
    			this.tests.getDebuggerValues(prop);
    			// show property
    			prop.push({name: "Property", value: "Value"});
    			for (var n in this.props)
    			{
    				prop.push({name: n, value: this.props[n]});
    			}
    			return [{
    				title: "LookUp",
    				properties: prop
    			}];
    		}
    // c3runtime/plugin.js debugger code
    // Full version: https://pastebin.com/fQsZhs4e
    TestsMgrKlassProto.getDebuggerValues = function (prop)
    				{
    					// show test result
    					prop.push({name: "Test", value: "Result"});
    					var i, cnt=this.tests.length;	
    					var info; 
    					for (i=0; i<cnt; i++)
    					{
    						info = this.tests[i].extra;
    						prop.push({name: info["name"], value: info["result"]});
    					}
    				};

    In C2Runtime everything works fine, but in C3Runtime the debugger values ​​are infinitely generated:

    How to fix it?

  • Added new addons:

    Rex_Chess

    Rex_Board

    Rex_Board_SquareTx

  • wertt22, I have updated links.

  • Rex_ZigZag added.

  • sTARKi I tested with the official behavior example in the latest release (r251) and it previewed without issue. Please, send me the .c3p file with this error.

    OK, I'll try to update this addon.

  • I finally added modules support to Firebase plugins. Thanks to Mikal for the help.

    Download link (Authentication, APIv3, LeaderBoard, SaveData): drive.google.com/file/d/1XiQxfsYW7OFi4bnPNZPycOEukNOwV43O/view

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I added modules support to all the plugins, that haypers asked except Rex_Firebase_ApiV3. I have a problem in it (more detailed here construct.net/en/forum/construct-3/plugin-sdk-10/third-party-addon-changes-156802/page-2

    If someone knows how to fix this, let me know. Here is the link to the plugins: drive.google.com/file/d/1KkF6GUkHG1nQ9D0UFdyw6siM44hQWF0I/view

  • Hello everyone! I'm adding modules support to Rex_FirebaseAPIV3 plugin and I stuck into a problem. How to fix the error on 11th line of the code about accessing the 'database':

    "use strict";
    
    {
    	C3.Plugins.Rex_FirebaseAPIV3.Instance = class Rex_FirebaseAPIV3Instance extends C3.SDKInstanceBase
    	{
    		constructor(inst, properties)
    		{
    			super(inst);
    			if (properties)
    			{
    	 	globalThis["Firebase"]["database"]["enableLogging"](properties[4] === 1);
    		 if (properties[0] !== "")
    		 {
    		 	this.initializeApp(properties[0], properties[1], properties[2], properties[3]);
    		 } 
    			}
    		}

    If you don't change anything (or replace globalThis with window), then the project fails to load in modules mode with the error that database is undefined. While in the classic mode, project is loading without any errors.

GameSoul's avatar

GameSoul

Member since 28 Mar, 2019

Twitter
GameSoul has 11 followers

Trophy Case

  • 5-Year Club
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

8/44
How to earn trophies