WackyToaster's Forum Posts

  • Constructs 3D shapes are (intentionally) relatively limited. I don't think an Arch like that will be possible with vanilla Construct.

    You can use 3rd party plugins

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

  • but there is an additional setting that causes this issue "Pause on unfocus"

    Oh, I never use this feature because it seems mostly pointless to me other than testing on suspend/resume triggers. This arguably could be considered a bug, but I tried to replicate it and it's not happening for me.

    "Pause on unfocus" only works in preview btw., at least according to the tooltip. The game always pauses on unfocus on export.

  • That's not possible. The whole point of a tilemap is to be tiled. The only way around it is probably to use an extra tilemap for every platform which could be a valid approach depending on how exactly your tilemap looks like.

    Another alternative could be a 9-patch construct.net/en/make-games/manuals/construct-3/plugin-reference/9-patch

    Otherwise, there's nothing wrong with using sprites.

  • Yes, tiles always snap to other tiles. The forum is a little broken currently so that's why my image doesn't show up.

  • when switching tabs in browser and returning to the game, it is unpausing automatically

    That seems a little odd. What events do you use to pause/unpause? Can you share a screenshot? I just tried with a very basic setup and it doesn't happen for me.

    Worst case you can probably work around it with on suspended/resumed conditions but there's possibly some error in your events.

    construct.net/en/make-games/manuals/construct-3/system-reference/system-conditions

  • Even if you clicked both buttons at the same time mousedown would be called for each button individually.

    That's the thing though, that doesn't happen. If I click & hold the right mouse button, the left mousebutton will not trigger any further mousedown events and vice versa. Clicking both at the same time has the same issue since one of them is bound to be clicked first unless you happen to get it frameperfect maybe? It seems like this listener is only able to register one button at the same time which seems wrong to me.

    You can’t directly query the state of a button with the browser so a solution is to just update some variables from mousedown and mouseup events, and then you can look at those variables to access the current button state.

    That's what I'm going to do, but I'll use the mouse plugin for it, because that actually works as I expect it to. That's also what I'm already doing for the keyboard inputs, except I don't have to go through the keyboard plugin for that, I just do:

    runtime.addEventListener("keydown", (ev) => this.keydown(ev));
    runtime.addEventListener("keyup", (ev) => this.keyup(ev));
    

    and it works. I'd actually prefer this method since it would work exactly the same. The mouse plugin only allows me to use isMouseButtonDown() which internally already tracks the state I suppose but makes it annoyingly inconsistent with how I handle the keyboard inputs. So I'd have to fire a customEvent to register onClick stuff.

  • I'm still not sure if you're asking to draw individual tiles off-grid or if you're saying your entire tilemap is snapping. You can drag & drop the entire tilemap to be whereever you need it to be, but within the tilemap, individual tiles cannot be drawn off-grid. The tilemap has a grid itself (it has nothing to do with the snap to grid setting) with the origin being the tilemaps position. So if you wanna draw off-grid tiles, you probably will need to use a second tilemap on top.

  • Update: I'm an idiot, I can just use the mouse plugin lmao

    Though I'm a little confused then what the point of the mousedown event in the runtime is.

  • You absolutely can. If snap to grid is turned off, you can (or rather should be able to) move the tilemap at whatever increments you wish. You can also try Alt+Drag which will disable snapping in general (even if snap to grid is turned on)

    Unless you're asking to draw individual tiles off-grid? That doesn't even make sense really, that's the whole point of tilemaps.

  • When in doubt

    supportqpd@construct.net

  • I'm setting up the mousedown event like this

    	runtime.addEventListener("mousedown", (ev) => doThing(ev));
    

    This works as expected for both right- & leftclick until I attempt to hold one and click the other. This should return ev.buttons = 3 except the event is not fired in the first place

    developer.mozilla.org/en-US/docs/Web/API/MouseEvent/buttons

    Using pointerdown doesn't work either. Is this a bug or am I doing something wrong?

    Basically I wanna do is

    	onLeftClick() {
    		if(rightButtonDown) doThing()
    		else doOtherThing()
    	}
    
  • You can update bundled addons by right-clicking the project name in the Project Bar, selecting Tools -> View used addons, and right-clicking the bundled addon. If you have a newer version of the same addon installed, there should be an option to update it.

    That's new to me :D, guess it isn't exactly something you can easily stumble upon by chance. Good to know!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • That is for sure an interesting project. I don't think drawing pixel by pixel on sprites is gonna work out.

    Have you looked into this example project?

    editor.construct.net

  • I found jquery is weird to implement. I never could get it to work by putting it into scripts or source files. It allegedly supports ES6 imports but alas it never works.

    But this addon works like a charm, add it to the project and you should be done. construct.net/en/make-games/addons/162/jquery-plugin

  • Do you have bundle addons active?

    I remember I had a similar issue and the reason was that the bundled addons would "overwrite" the installed addons even if they are an older version. This makes sense I think for compatibility.

    To update, I think you can simply disable bundle addons, close & reopen project, enable bundle addons again. You need to make sure all addons you had bundled are installed otherwise you won't be able to open the project with a missing addon. And just in case, make a backup, you never know when things are going to implode.