GeoffB's Forum Posts

  • In the "spawn bullet" event, you need to set the bullet's angle of motion based on the angle of the cannon. Or depending on the orientation of the cannon sprit you might need to offset by 90 degrees.

  • You need to make sure that you are picking the correct instance of the enemy. In your case you should tag enemies that have been hit (with a boolean or something), and only change the animations of those enemies.

    But I think you are overcomplicating this. Are you trying to show hit damage on the enemy by changing their animations? If so, you should keep a variable like hitPoints on each enemy. Deduct 1 from their HP when hit, and then set their animation based on their HP.

  • Doesn't seem like it's possible to disable it entirely, but you could set rotateSpeed to 0 every tick while it needs to be "disabled" 🤷‍♂️

  • The community can try to help but more information is needed. Can you share a screenshot of your events?

    And just to state the obvious, you want to use the Object->Destroy action to destroy objects.

    EDIT: I see your second post now.

    What is likely happening is that only the last instance is getting destroyed, as that is the instance currently picked. You should use a sub-event and add the condition "Pick All" -> cone. Then destroy. This should work

  • That would definitely solve a lot of problems. If HTML objects behaved just like regular C3 objects, it'd go a long way in encouraging users to do things with HTML. Right now it feels too disjointed, like we're working with two vastly different systems despite there being so much under the hood that they have in common. Bringing these two spheres closer together will go a long way!

    But yes, please, anything to help me avoid having to build my own text entry system system (again)! :P

  • Yeah no doubt that HTML is powerful, and very quick to do certain things.

    In your example I would absolutely just build a table using events, and have done so many times.

    I'd do it that way because I might want a dialogue box to appear on top when a user taps something. Maybe I want a gradient that is across the whole screen. Or, what I do most often, is I want to populate that table with sprite fonts that I use elsewhere in my project, and sprites I use elsewhere. These contents are built using a mix of hierarchies, templates, and containers, using C3-specific techniques that I've learned through years of practice. Maybe I just want a sparkly particle system to appear where the user taps. One of my current big projects uses an entirely world-space UI with all sorts of pretty effects. It's gorgeous, but it was a nightmare to put together.

    I'm not a classic developer, so I'm put off by the idea of learning new languages, but I currently work full-time as a Construct dev. Every other dev in the team is amazed at the speed of this software, and appalled at the lack of UI support. I stand by Construct, and I'm probably as tired as you are of hearing about UI! 😂

    I once used an adjustable wrench to knock in a nail because I had no hammer. It did the job, but I wish I had a hammer at the time.

  • HTML is nice and all but it's simply not a desirable option. Here are some things you can't do with HTML-based UI:

    Render it behind non-HTML objects

    Z-ordering, Z-elevation, mesh distortion, paste to canvas, use as a 3D face object, or any sort of "world-space" UI

    Use native effects or blend modes

    Use Construct objects like sprites/9-slice/etc.

    See your results in the layout

    In addition, you'll have to use CSS to make anything look nice. CSS is super powerful if you're a web designer trying to flex your skills. It's a pain for everyone else on the planet.

    OP, this is the reality of Construct. Either learn html/css and cobble together a UI, or roll your own. I'd say that third-party plugins are kind of dead in the water right now (usable, but less reliable as time goes on), at least until someone picks up the torch. There is some progress happening in that department, from what I've seen in the community.

    Honestly, Construct does soooo much already that it's probably going to be quicker for building a game than Unity (depending on the game). I hate building UI but I do it every time, and get quicker every time, often pulling in functions and assets from other projects.

  • You’re getting the length of the actual string “t” instead of the contents of the variable t. Otherwise, your logic looks right.

  • I went through this same headache for a pinball game. Eventually I settled on toggling the ball’s physics on/off for rails. Movement on the rails was handled with timelines - I found that having precise control over beziers was actually pretty nice. Timeline speed is based on the ball’s entry velocity.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Anchor will take over positioning and make your life difficult. I suggest you rather anchor a helper object to the corner, and use events to position the joystick and its components to that helper on start of layout.

  • I haven’t used C2 for ages so I’m not sure of what addons are still supported, but Rex made a Mode7 effect that I remember working quite well. rexrainbow.github.io/C2RexDoc/c2rexpluginsACE/behavior_rex_mode7ground.html

  • That post is from ages ago, and it's now much easier to do thanks to the 3D Shape object.

  • Do you have any code that handles these interactions? If so, you might not be picking the correct player, and it's always picking the first instance.

    Also, don't use their sprite animations for collision checking and movement. Use a holding object that doesn't change and parent the player sprite to that object.

  • Difficult to tell what's causing this without more info. If you aren't already, you should use a "holding" object to handle the player's movement and collisions. Just set it to be a single frame with whatever collision shape you want. Then parent the player sprite to that object.

    Basically the idea is that you shouldn't change animations on the object that handles movement.

    See this tutorial if you haven't already: construct.net/en/tutorials/platformer-game-2329/page-5

  • You can have massive layouts without too much trouble, so I wouldn't worry about there being a practical limit. Just make sure that there isn't tons of logic like collision detection or physics simulations happening all across the layout, or things might slow down. Also be sure that User Render Cells is enabled on your layers.