XHXIAIEIN's Recent Forum Activity

  • For example, you have a dictionary of object type named call 'PlayerData'. Then you added the 'Level' key to the dictionary.

    const playerData = runtime.objects.PlayerData.getFirstInstance().getDataMap();
    const playLevel = playerData.get('Level');
    console.log(playLevel);
    

    Set Value

    const playerData = runtime.objects.PlayerData.getFirstInstance().getDataMap();
    playerData.set('Level', 20);
    console.log(playerData.get('Level'));
    
  • here are many ways to implement:

    HTML element

    If you are using the HTML element, You can create a 'Text Input' object and set its Type to 'Textarea', which is the easiest way.And If you want to change its CSS style, you can create a new 'Stylesheet' file in the File Folder.Such as hiding scroll bars, Disable borders, changing text size, font, etc.

    Blend mode

    You can use the 'Destination out' effect in Blend mode to use a 'Mask' object to block the screen and only display part of the text.

    text Mask Scroll Clamped - Example by Federico Calchera

    cdn.discordapp.com/attachments/253490735268102144/1068598442294784040/textMaskScrollClamped.c3p

    Also, you can use only 1 Mask object to create the effect of a mask, as sub-layers.

    cdn.discordapp.com/attachments/225550155531812865/1115557475614216222/MaskTextScrolling.c3p

    String Expressions in text

    Use 'tokenat', 'tokencount', 'min', 'max', 'mid' system expressions to split the string to implement the text scrolling.And You can find the documentation for these expressions here:Manual - System expressions - Text

    Scroll Text - Example by Stan Merezhko

    dropbox.com/s/61tfvg3y1b8faby/ScrollText.c3p

    Text Scroll Mask - Example by Zackarotto

    cdn.discordapp.com/attachments/225550155531812865/923122064955674704/TextScroll-Mask.c3p

  • R344 Platform inconsistently when side close to the wall still moving. Since this is not a bug, it was not committed to github, just wanted to discuss it here.

    Take the built-in platform game example as an case: In the R366 version, the Platform will not be considered as 'is moving' when it side close to the wall, When he moves to the edge of the wall, he will stop and no particle animation will appear. But on R344 it behaves inconsistently.it will still be moving.

    R336: When walking on a wall, it stops.(Animation: Idle, particles: stop)

    R344: When walking on the wall, it will continue to be moving.(Animation: Walk, particles: playing)

    This is a screen recording of the same example in different versions, you can observe the difference between R336 and R344.

    Open Example .c3p R336 R344
    #open=world-to-hud-position Example1-R336 Example1-R344
    #open=shockwave-spell Example2-R336 Example2-R344

    details: Windows 10 / Chrome 113.0.5672.129 / Approx 8 GB / NVIDIA GeForce RTX 3050 / Direct3D11 / WebGL 2.0 / Monitor 60 Hz

    ----

    Is this a BUG? Not exactly. It's just a tricky way to rely on "abnormal" platform performance. Because on other monitors, the above situation is different. Here is an observation of the same case at 144Hz:

    Example2-R336

    R344: When walking on the wall, it's twitching

    R336: When walking on a wall, keep animation playing.

    Apparently R344 is look better.

    In order to adapt to this change, I had to change the method of control player animation, so that walking on the wall can stop and no longer create dust particles. For example, in the case of CAE BRIDGE(#open=cave-bridge) , VectorX is used to judge based on the speed of movement.

    If possible, I wish Platform could have more control over the behavior near the wall. For example when close to a wall:

    - keep moving

    - slow down until stop

    - stop immediately

  • In "Tween On Finished" event you can pick all sprites and check if any of them are still running tweens.

    I tried this method but it does not seem to work. I also tried using On "Tag & loopindex" Finished to judge the last played Tween, but that doesn't seem to work either.

    It is always displayed before the last one has finished playing.

  • I want to make an opening animation of the sprites entering in order and start the game when they are all done. But How do I wait for all Tween play finished in the 'For each' loop?

    This file is to want to wait until all Tween completed, and then display the button.

    cdn.discordapp.com/attachments/253490735268102144/1113389910553022484/tween-wait-complete.c3p

    I know I can hardcode it to wait 2 seconds and display it, but I'm wondering if there is a way to use 'wait for previous actions to complete'.

    One more question, how should I make sure that the AJAX requests for files, maybe three or five files, wait for them all to finish loading before starting the header animation?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • template challenge room

    editor.construct.net

  • Maybe I need a 'Sine In' or 'Sine Out' wave

    Current:

    Expected:

  • Cheatsheet:

    Level 1

    {
     "name": "Cheems",
     "age": 18,
     "score": 100
    }
    

    return "Cheems"

    JSON.Get("name")
    

    -----

    Level 2

    {
     "team": 
     {
     "name": "Cheems",
     "age": 18,
     "score": 100
     }
    }
    

    return "Cheems"

    JSON.Get("team.name")
    

    -----

    Level 3: Array

    {
     "array": [123, 456]
    }
    

    return 123

    JSON.Get("array.0")
    

    -----

    Level 4: Array

    {
     "team": 
     [
     { "name": "Cheems", "age": 18, "score": 100 },
     { "name": "Marmot", "age": 17, "score": 95 }
     ]
    }
    

    return "Cheems"

    JSON.Get("team.0.name")
    

    -----

    Level 5:

    Note that it does not start with {}, but [] as a JSON array

    [
     {
     "name": "Cheems",
     "age": 18,
     "score": 100
     },
     {
     "name": "Marmot",
     "age": 17,
     "score": 95
     }
    ]

    return "Cheems"

    JSON.Get("0.name")
    

    -----

    Level 6:

    {
     "team": [
     {
     "name": "Cheems",
     "age": 18,
     "score": 100,
     "fruit": ["Apple", "Banana", "Cherry", "Durian"]
     },
     {
     "name": "Marmot",
     "age": 17,
     "score": 95,
     "fruit": ["Apple","Berry"]
     }
     ]
    }
    

    return "Banana"

    JSON.Get("team.0.fruit.1")
    
  • Currently C3 typewriter unable to do this. You can vote for this feature here.

    construct23.ideas.aha.io/ideas/C23-I-24

    This is a way to use len() and mid() to make a typewriter.

    cdn.discordapp.com/attachments/225550155531812865/1100092755297980527/typewriter_pause.c3p

  • Maybe something like this?

    editor.construct.net

  • Try changing 'direct movement' to 'None'

XHXIAIEIN's avatar

XHXIAIEIN

Member since 26 Mar, 2016

Twitter
XHXIAIEIN has 11 followers

Trophy Case

  • 8-Year Club
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • Enduring Visitor Visited Construct.net 90 days in a row
  • RTFM Read the fabulous manual
  • x46
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x10
    Lightning Draw First person to up-vote a new Construct 3 release
  • x9
    Great Comment One of your comments gets 3 upvotes
  • Delicious Comment One of your comments gets 10 upvotes
  • Email Verified

Progress

20/44
How to earn trophies