2DManiac's Forum Posts

  • The most common way, I think, is to use physics. On the example browser, look up the example "Physics: Distance Joint" and "Physics: Vehicle". Those should help you with learning the needed concepts.

    If you want a more traditional look — non-physics based — then you can use hierarchy. Here's how you can do it with hierarchy:

    Create the following objects:

    • 9-patch "Rope"

    - make its graphic a square filling up the canvas

    - On the layout stretch the object horizontally

    - set its "Origin" to "Left"

    - add the behavior "Sine", "set Movement" to "Angle"

    - rotate the object to make it start upright

    • Sprite RopeGrabDetect

    - make it a circle

    Events:

    When the rope is created, attach a RopeGrabDetect object to the rope.

    Event: Rope > On Created

    - Action 1: Create Object > RopeGrabDetect, X = Rope.BBoxRight, Y = Rope.Height/2

    - Action 2: Rope > Add Child > RopeGrabDetect

    Attach the player when it collides with RopeGrabDetect.

    Event: Player > On collision with RopeGrabDetect

    - Action 1: RopeGrabDetect > Add Child > Player

    - Action 2 (after the previous action): Player > Set Position > X = RopeGrabDetect.X + (adjust to your liking), Y = RopeGrabDetect.Y + (adjust to your liking)

  • Agree, I've been working on some UI improvements myself too haha, currently working on a custom button engine. But anyway, good luck on your projects! Looking forward to seeing what you do next!

  • Damn this is very impressive! I started developing a space 4x prototype in Construct 3 myself a couple years ago, but dwindled development because of the 3D limitations of the engine at the time. Found a lot of problems with effects on stars, etc. But with the new 3D updates I thought about picking it back up.

    If this is a serious project we could join forces, maybe our visions align :)

    Here's my project (which I just noticed you actually commented on!):

    construct.net/en/forum/construct-3/your-construct-creations-9/nova-imperium-3d-space-4x-182652

  • I had actually never used bookmarks, I didn't know exactly what they were used for, but it does facilitate navigation a bit. I appreciate it!

  • I'm not sure if anyone has ever requested this or not, but working on large event sheets, I often find myself needing to check some different part of my code (maybe some 50 lines away from what I'm working on right now), and I'm forced to:

    - scroll down

    - look for it

    - check whatever I need to check

    - scroll up

    - and look for the section I was working on.

    On big event sheets this becomes pretty tiring and time consuming.

    Using groups doesn't help a lot because it still requires you to scroll up and down, and often open and collapse those groups. They offer organization, but not navigation ease.

    In UE5 for example, when you collapse some code into a function or macro, you can open them in a separate tab, and that allows you to quickly go back and forth between the main code and the function, without needing to scrollll down, and then scrollll up. This makes eventing super fast.

    It's just an example, of course this would be difficult to implement in Construct 3, but I think the solution could be rather much simpler: Allow the user to open duplicates of the same event sheet.

    This would allow users to place the same event sheet side-by-side but in different sections of the code. That way, we could have a window focused on what we're working on and another showing the code we need to reference (both from the same sheet).

    Wondering if this would be a possibility.

    Tagged:

  • Let's leave it at that.

  • Hey, while working on a project I've come across this issue.

    After creating a javascript inline in an event, even if I don't place any code inside (still happens if I place code, fist noticed it when trying to console log), it caused all HTML objects to disappear.

    Step 1.

    Step 2.

    Step 3.

    Step 4.

    Happens with Typescript too. I very much need to use javascript in this project, so it would be great to have a fix in the next version.

    Cheers

    Edit: After testing I realized this only happens when WebGPU is set to Auto or Yes.

  • You do not have permission to view this post

  • You do not have permission to view this post

  • Hello! Here's my small contribution to the community.

    It's a card game Template similar to the style of games such as Slay the Spire.

    It allows you to draw cards, have them laid out on the bottom of the screen as if holding the cards, and play the selected card.

    A few details:

    - Game uses 2 arrays: Draw Pile and Hand. Cards are moved from one array to the other. Both UID of the card and a Card ID (that you can use to populate with your own card types) are stored on the arrays.

    - The state-machine for the card dragging might need some improvements.

    - You can setup certain Global variables in the objects GameManager and HandZone.

    Have fun!

    Link to Demo and Template:

    construct.net/en/free-online-games/basic-card-game-template-79065/play

  • Hey Ashley, thank you for the response!

    The idea is to avoid having the html file being stored locally on the instance, because the base HTML content isn't global to all instances (for instance, like a sprite's animation is), so making changes to one would force me to go and manually update the content of each single instance.

    Getting the html content directly from a file solves this issue. It also makes it easier to make quick edits to the content with code highlighting.

    The AJAX option worked (funnily enough I'm actually using the full document across multiple html elements without issues). It does have the limitation of only being able to access LastData, but there are workarounds.

    Even though the AJAX method does the job, having been relying heavily on the HTML Element object recently, I think it would be really useful to have an action that does this directly, mainly because it would allow us to take full advantage the built-in IDE when coding the html content.

  • Hello, what's the best way to load the entirety of an HTML file from the Files folder into an HTML Element, as opposed to having the content pasted inside the object on the layout.

    Can't seem to find a direct way of doing it.

    Cheers!

    Tagged:

  • You do not have permission to view this post

  • Thanks so much! I wasn't aware of this, it works perfectly!

  • How do I access project files through an HTML Element Object?

    I'm trying to create some icons in an HTML Element for a rich text editor that I'm integrating on my project. However I'm having trouble knowing how to access those files through html, or by getting the files URI.

    - Using the actions "Create sprite image element" and "Position object at element" is no good because the images don't look good when imported this way, and the user is able to drag the images around if they click them, which doesn't look very normal for what it's intended.

    Tagged:

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads