Kaisirak's Recent Forum Activity

  • The bug still exists in [r163]. And it seems like it affects every shader using vTex for sampling.

    Update: Turns out it's the <extend-box-vertical> and <extend-box-horizontal> that are broken when you set their value at anything but 0.

    vTex.x = 1.0 and vTex.y = 1.0 used to mean bottom right corner, but it seems to be reversed now, and now points to top right.

    On top of that, shaders specific to a game object seem to receive the vTex.y from the layer they are in world space, not from the pixel in object space.

    Here is an example file: http://www.mediafire.com/download/uwqa8 ... ndcapx.rar

    TL;DR: vTex.y now 1.0 - vTex.y and is received as layer vTex instead of object vTex but only when setting <extend-box-vertical> or <extend-box-horizontal> to anything other than 0

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Projects with webgl effects that worked before updating now show this when I try them: "Uncaught ReferenceError: viewLeft is not defined" in layout.js line 1663

    This happens only when using a shader not made by Scirra but Brad Larson, Evan Wallace or myself for example (the stretch or swirl effect for instance or any custom made shader)

    UPDATE: It would appear that changing <extend-box-horizontal>0</extend-box-horizontal>   to any value other than 0 and restarting construct 2 solves this problem. So my guess is when checking the for the vec2 origin, origin.x is set to null instead of 0

    Browsers affected:

    Chrome: yes

    Firefox: yes

    Internet Explorer: yes

    Operating system & service pack: windows 7 64x

    Construct 2 version: r160

  • That makes sense, thank you Ashley

  • I'm writing a shader, and I was wondering if there is anyway to only check a specific layer when sampling the background.

    For example when I use:

    lowp vec4 back = texture2D(samplerBack, mix(destStart, destEnd, vTex));

    if (back.a > 0.5)

    is there anyway to exclude or specify a layer, or is it always the sum of every layer other than the current layer ? So in this instance back.a would only refer to the alpha of the layer under the current layer.

  • Is there a way to get the value for the WebGL effects parameters?

    For example I created a shader with an Intensity value that's on my layer 0, is there a way to do Layer[0].Effect(myeffect).Param(0) and get the current value ?

    I could store them manually on the side, but if I don't have to, I'd rather have a cleaner project.

    Thanks

    I voted for modularity. Being able to have a HUD that remains through the game without having to manually code them into place would be a huge time saver for example.

    And as for multiplayer, there is already a functioning plugin by zack0wack0 if I remember correctly.

    It might not be the most optimized thing in the world, but I did create a multiplayer game with it and node.js , it was playing fine with 4 people (well, 3 and a local player). Granted there was a lot of client side prediction and it would have probably exploded with 16+ people, but it was playable.

    Anyway, like someone above me said, you use multiplayer in some game but you would use modularity in all of them.

  • No problem, as for the choose, what I meant was instead of having choose(1,2,3,4) try using choose(1,1,2,2,3,3,4,4). That way even if there is only one option there will actually be two.

  • Thank you, I'll give this a look

  • The thing is, I don't want to create an event for 50 types of enemies, meaning I wish something like this were possible:

    system:create(typeOfEnemy)

    instead of having to do:

    if(typeOfEnemy == 1)

    {

    system:create(type1Enemy)

    }

    else if(typeOfEnemy == 2)

    {

    system:create(type2Enemy)

    }

    else if(etc)

  • Hey sorry to bump this but I could really use an answer.

    to Simplify my question, can you choose which object to create at runtime, at least in a family ?

  • Yes you "draw" every sprite you're gonna use in a specific layout, this is by design.

    In my opinion this is a design flaw, if the object is in your project you should be able to create it whether or not one already exists. But since I don't know the inner workings of C2 I have no idea of how feasible it is, and I trust Ashley.

    Best thing you can do is either create a layer or a family with all the object you had to create, and then use on start of layout -> destroy for every object in the family or layer.

    Ninjaed by Kyatric, you sneaky devil

Kaisirak's avatar

Kaisirak

Member since 14 Aug, 2012

None one is following Kaisirak yet!

Trophy Case

  • 12-Year Club
  • Email Verified

Progress

13/44
How to earn trophies