LittleStain's Forum Posts

  • Just add conditions for all brick types.

    so:

    System compare two values : Brick1.count = 0

    System compare two values : Brick2.count = 0

    System compare two values : Brick3.count = 0

    System compare two values : Brick4.count = 0

    System compare two values : Brick5.count = 0

    System compare two values : Brick6.count = 0

    • System goto layout level2

    you will only goto the new layout if all these condoitions are met, so if all instances of all bricks are destroyed.

  • Project bodyshapes is nearing testfase:

    <img src="https://dl.dropboxusercontent.com/u/48563442/Bodyshapes-startschermen.jpg" border="0" />

    All screeninfo is in Dutch and all adjustable sizes are in cm at the moment, but after the testfase Other languages and feet and inches will probably be integrated.

  • Is it possible to make the p1x and p1y variables of the objects or is there any other way to create a reference between the objects and their desired pin-position? if so you could just make a function.

    on object dropped call function"CheckDistance" with parameters (object.x,object.y,object.pinlocationx,object.pinlocationy)

    on function "CheckDistance"

    (subevent) - Sytem compare values : distance(param(1),param(2),param(3),(param(4)) < 22

    and add your actions.

  • If it's for 50+ objects you should probably look into doing it with the function object and/or families. Also if many of those objects are instances of the same object you should look into picking instances.

    the distance(x1,y1,x2,y2) is just a value you can put into your system compare values event.

  • What's wrong with the way you do it now?

    You want to check for two different things, but do it in 1 line?

    You could change the compare two values to

    if distance(objectname.x,objectname.y,p1x,p1y) < 22

    but that would make a circle of 22 pixels around your variables instead of the square you use now.

  • for the webstorage part,instead of set key in the start of layout you should do something like:

    system set value score to webstorage.localvalue("score")

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Did you read my last post?

    I'm talking about adding an instance variable to a global object or setting the value in a global array and retrieving it after resetting the global variables.

  • Would using a global object to get the variable from one layout to the other work?

  • If you have a lot of global variables already it wouldn't hurt to make one more for the global score that you don't reset.

  • So actually your throwing something away that you want to keep?

  • I thought global variables are only reset if you have an event to reset them?

  • system every tick - character platform simulate pressing right.

  • Easiest way is to use bullet behaviour with gravity.

  • You should use subevents.

    After you pick the insect which is hungry, pick the insect to chase in a subevent. In another subevent (as long as it is a direct subevent if your for each) if you reference an insect it will be the one originally picked.