[PLUGIN] Paster

From the Asset Store
Antisuspend Plugin
$7.20 USD
20% off
Antisuspend Plugin for Construct 3 prevents the runtime from getting suspended.
  • irina

    Not a bug. In C2 events are run top down so both "double tap" conditions are triggered. Fix it by using "else" instead of "double tap" twice.

    On double tap

    --- dragging = 1

    ------ do something

    --- else

    ------ do something else

  • R0J0hound

    Oh, yes... your right... i allways forget on "else"... shame on me!!

  • Added a bugfix:

    • there was an error if you destroyed a paster object when webgl wasn't available.
  • Hi there. Firstly, this plugin is so great and really fun to play around with, thank you so, so much for this.

    I have a little puzzle though and I was wondering if someone could perhaps help. Is there any way for objects to be pasted in the same z-order as they appear on the layer? I'm playing about with a little top-down / isometric, split screen thing where objects often change position within the z-order when moving about.

    I use the following event to determine where they are on the layer:

    but of course this doesn't translate to the order by which they are pasted.

    I hope this makes sense, it's a bit difficult to explain. I'd be very grateful for any suggestions as I'm at my wit's end.

    Thank you kindly,

    Keep well,

    Jack

  • You could use the .ZIndex expression to get the z order of the object, then you could draw the instances in the same order with:

    For each behindinfront ordered by behindinfront.ZIndex ascending

    --- paster: paste behindinfront

  • Thanks so much! That works a treat!

  • Hello R0J0hound , can you please help me with this weird thing here..?

    I am trying to make a pseudo-3d room with paster and for the most part it works great! But for some reason the textures are distorted, this is evident when they have straight lines and those "brake" and get jagged in some places...

    Please have a look at this example capx: http://www.eli0s.com/Tests/Paster_Perspective_Room.capx (right click and save link as)

    Am I doing something fundamentally wrong?

    Thank you in advance for any tip!

  • eli0s

    This post is relevant:

    Basically it's because the quads can't be drawn with perspective since there's no real z.

  • R0J0hound , damn, it would be too easy if it worked out of the box

    I saw your other examples and both workarounds are too difficult for my abilities. I'll just stick to the plain good ol' parallax for now...

    Thank you so much for taking the time and answering me R0J0, I really appreciate it!

  • TiAm Somebody

    I'm not having much progress with getting the canvas pasting to work reliably. It's currently kind of random if it works or not, so I may end up having to go a slower route of making an off screen texture and rendering everything to that.

    Hey, any chance of you working your rojo-mojo on this?

    I use this functionality for the pause menu in my current project to do a 'background blur' of all layers but the top menu layer. I just grab the canvas when pausing, paste it onto the paster object, and use an animated blur effect on it.

    Problem is...at some point 'load texture from canvas' stopped working on my mobile. Used to work in cw7 and chrome mobile, iirc. Works fine on desktop, except in IE (and it never worked there).

    The only other way of doing this (other than the painfully slow CanvasSnapshot function) is to apply the blur to all layers except the top, which is too slow on mobile.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • TiAm

    I haven't touched it in a bit, but one thing I found was it seems to grab the frame 4 frames back but not always immediately. If you use the "load texture from canvas" four frames in a row then it should for *sure grab the canvas. At least as I recall.

    *tested with chrome on desktop. It might be something internal to how the browser works.

    The the main issue is copying the canvas to a texture is not undefined behavior according to the webgl spec, which might explain why iexplorer doesn't work. i had thought it might be an issue of when I grab the canvas but I haven't been able to find any place that works better.

    One thing that I could investigate further is enable a flag when the webgl context is created to tell it to save the canvas' texture after every frame. The drawback is it's not something I can do from the plugin, I'd have to change it in c2's runtime. The second drawback is the webgl spec has an ominous warning that says enabling that flag can have an overall performance impact.

  • R0J0hound

    Thanks for replying. The flag idea does sound like it would incur a hefty perf overhead, but...well, I think you know more about this than me.

    I'll try capturing the canvas multiple times and see if that works.

    Shame there isn't a good, fast way to capture the canvas built into the webgl spec, seems a bit of an oversight.

  • I've been able to get spritefont to paste as expected.

    Pasting the text obejct works, but appears to paste erratically. Its position is off, and it pastes the text upside down.

    Any idea as to why?

    Looks like pasting text objects almost works properly, any chance of making it work as well as spritefonts?

    Thanks for your continued support of this plugin.

  • Probably the most impressive plugin I've seen so far. I love it.

    Are the versions in the OP outdated though? Is there a better renderer yet?

    Thanks for everything though, Rojo!

  • hmott

    The fact it's flipped is due to some graphics card drivers. It can be detected and corrected, but thanks to chrome and firefox updates I can no longer use webgl on my machine, so I haven't touched that portion. I'm hesitant to do a fix that I can't test.

    The download is the latest. All it does is leverage whatever rendering C2 already does.

Jump to:
Active Users
There are 3 visitors browsing this topic (0 users and 3 guests)