chunchun's Forum Posts

  • I had the following problems with the plug-in:/nError report information/nType: unhandled rejection/nReason: Error: this.FakeWake is not a function TypeError: this.FakeWake is not a function at MyCustomInstance.OnCreate (blob:https://editor.construct.net/0e8e564a-bc72-4550-9ea8-a594571a05e4:18:18) at ms.dEb.Yd (https://editor.construct.net/r269/main.js:1924:146) at d.Yd (https://editor.construct.net/r269/projectResources.js:686:401) at d.Jhc (https://editor.construct.net/r269/projectResources.js:586:462) at window.lvb.hu (https://editor.construct.net/r269/main.js:1875:353) at editor.construct.net/r269/projectResources.js:2479:403/nStack: TypeError: this.FakeWake is not a function at MyCustomInstance.OnCreate (blob:https://editor.construct.net/0e8e564a-bc72-4550-9ea8-a594571a05e4:18:18) at ms.dEb.Yd (https://editor.construct.net/r269/main.js:1924:146) at d.Yd (https://editor.construct.net/r269/projectResources.js:686:401) at d.Jhc (https://editor.construct.net/r269/projectResources.js:586:462) at window.lvb.hu (https://editor.construct.net/r269/main.js:1875:353) at editor.construct.net/r269/projectResources.js:2479:403/nConstruct 3 version: r269/nURL: editor.construct.net/r269//nDate: Wed Nov 03202115:21:25 GMT + 0800(China standard time)/nUptime: 336.1 s/n/nPlatform information/nBrowser: Chrome/nBrowser version: 88.0.4324.104/nBrowser engine: Chromium/nContext: browser/nOperating system: Windows/nOperating system version: 10/nDevice type: desktop/nDevice pixel ratio: 1/nLogical CPU cores: 4/nApprox. device memory: 8 GB/nUser agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.104 Safari/537.36/nC3 release: r269 (beta)/nLanguage setting: zh-CN/n/nWebGL information/nVersion string: WebGL 2.0 (OpenGL ES 3.0 Chromium)/nNumeric version: 2/nSupports NPOT textures: yes/nSupports GPU profiling: yes/nSupports highp precision: yes/nVendor: Google Inc./nRenderer: ANGLE (NVIDIA GeForce GT 730 Direct3D11 vs_5_0 ps_5_0)/nMajor performance caveat: no/nMaximum texture size: 16384/nPoint size range: 1 to 1024/nExtensions: EXT_color_buffer_float, EXT_color_buffer_half_float, EXT_disjoint_timer_query_webgl2, EXT_float_blend, EXT_texture_compression_bptc, EXT_texture_compression_rgtc, EXT_texture_filter_anisotropic, EXT_texture_norm16, KHR_parallel_shader_compile, OES_texture_float_linear, WEBGL_compressed_texture_s3tc, WEBGL_compressed_texture_s3tc_srgb, WEBGL_debug_renderer_info, WEBGL_debug_shaders, WEBGL_lose_context, WEBGL_multi_draw, OVR_multiview2

  • I'm not sure why you're asking. Isn't using a single main.js script already the most convenient way?

    Because every page has some method that needs to be initialized or executed in tick. I don’t want to cram all the different page methods into Main. JS inside. Is there a better way?xd

  • The variable probably does not have global scope. Make sure it's a property of globalThis, i.e. globalThis.hackGlobalPunchesCoordinates, to ensure it really is accessible everywhere.

    Hi, Ashley, I want every new JS page to have access to the tick and layoutstart func. What am I supposed to do. The current practice is to addListener < tick > and < layoutstart > on the <main.js> page to connect each new page. Is there a more convenient way..

  • The newest beta release has added mouse control camera features. Please take a look at the release notes.

    Thank you.~~~~ I noticed the latest update

  • Not sure if this is helpful, but this plugin came to mind (assuming you meant 3d model):

    https://kindeyegames.itch.io/c3-3dobject-alpha

    Of course, I'm also hoping there will be 'official' support for something like this soon. :)

    Thank you ~ ~ ~ also do you know what method can you mouse control camera?

  • Hello, Ashley! How Do I import my own model. Or how to turn the model into something that C3 can recognize.

  • The Functions feature does not allow to have different function definitions in various event sheets.

    Nevertheless, you could have your function click in a common Event sheet (an event sheet that you include in your other events sheet) and check which layout is currently executed within the function itself.

    You perhaps could also look into the "Function maps", to allow your "single call" to call different function based on the context of calling.

    Hi, Thanks for the answer, but I’m still looking for this plugin. The last plug-in that worked is no longer available

    I prefer the concept of a Listener event, like Oncreat Ondestroy.

  • Like This:

    	On click button:
    			call "click"
    
    	《in ITEM eventSheet》
    	on "click":
    		*******
    
    	《in Player eveentSheet》
    	on "click":
    		*******
    
    

    I mean, in different event tables, you can give different feedback based on this signal, similar to listening mechanism, similar to customEvent of JS.

  • (1) you can add behavior 《NO SAVE》 to the updated object.

    But what if the updated object needs to be save later.

    Is there a good solution

    thank

  • Hi, Ashley

    How to use save and load correctly

    I used save In an old game.

    Then my game updated some of the props, plants in the scene.

    When I loaded in the new game, the newer props and plants disappeared.

    The game is constantly updated, adding some clouds, some decorations and so on

    But when you load the old games, those updates are gone.

    How am I going to fix this?

  • Hi, Ashley

    C3 is the Entity component system?

    I found the description of ECS to be very similar to how C 3 works

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Just tested this:

    > function repeatEveryMillisecond(f, ms) { return new Promise(res => setInterval(f, ms)); }
    
    repeatEveryMillisecond(() => {
    const now = new Date(Date.now());
    console.log(`${now.getHours()}:${now.getMinutes()}:${now.getSeconds()}`);
    }, 5000);
    

    Thank you!!!

    It works in the browser.

    But execute this function in C3 tick(). He’s not functioning properly.

  • > You can use

    >

    >

    > > function waitForMillisecond(ms) { return new Promise(res => setTimeout(res, ms)); }
    > 
    > console.time()
    > console.log("Wait 1000 milliseconds");
    > await waitForMillisecond(1000);
    > console.log("Waited");
    > console.timeEnd();
    > 

    >

    >

    >

    > > function repeatEveryMillisecond(f, ms) { return new Promise(res => setInterval(f, ms)); }
    > 
    > repeatEveryMillisecond(() => {console.log(Math.random())}, 1000);
    > 
    > 

    waitForMillisecond It’s working really well

    But repeatEveryMillisecond() It didn’t work out. Still waiting for * s, then every tick run

  • You can use

    > function waitForMillisecond(ms) { return new Promise(res => setTimeout(res, ms)); }
    
    console.time()
    console.log("Wait 1000 milliseconds");
    await waitForMillisecond(1000);
    console.log("Waited");
    console.timeEnd();
    

    > function repeatEveryMillisecond(f, ms) { return new Promise(res => setInterval(f, ms)); }
    
    repeatEveryMillisecond(() => {console.log(Math.random())}, 1000);
    
    

    thank you for your answer!!!

  • What I’m trying to say is that it’s not really code, it’s just a literal representation of the event table. You Don’t need it to have JS capabilities. It’s a literal representation of the event table, not the code!

    You might say there is JS. Don’t worry about the code form of the event table.

    But today it’s aimed at people who can do it on their own.

    The textual form of the event table, on the other hand, provides direct access to all the things that the event table can do.

    For example: all properties and methods of all behavior. JS can only access a small amount of behavior that exists in the API documentation

    All properties of all objects

    All of Syetem’s behavior and expressions

    All properties and expressions of the special effect

    All properties and expressions of particles

    (What I’m trying to say is, anything you can do in the event table, you can do here, because it’s just the text of the event table)