Trent123's Recent Forum Activity

  • Thanks for responding. I know everyone's moved on to Construct 3, so this forum is pretty quiet. Appreciate it.

  • This is so frustrating. I'm getting back into Construct 2 after many years, and this is a issue I know I struggled with back in the day.

    I have 70 objects in a family. Each object has a instance variable (text), with it's name.

    So I want to have a text box display the value of this instance variable, once the object is spawned on screen.

    How do I call this created object's instance variable, when its created by a call to the family?

    At this point, I have no instance variables on the family.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • O jeesh... nevermind.

    "If you add an instance variable to a family, all the object types in the family inherit the instance variable."

  • In your capx though, you have given the Family an Instance Variable of "HP", and both objects within the Family each have an "HP" instance variable..?

  • Um you shouldn't need to pick via uid, families do all that for you.

    All you have to do is subtract from the family, as the particular object is already picked.

    Just make sure the variable belongs to that family.

    OK. I know this is over 2 years later, my apologies. But how did you get a Family Instance Variable with the same name as a Object Instance Variable??

  • Could we possibly have a poll for the forum users to vote on the most used/popular ad networks they use, or would like to use, with their Construct 2 apps? Scirra can then use this to determine what ad networks can be added as plugins.

    I really find the lack of easy-to-implement ad plugins within Construct 2 frustrating. I even bought cranberrygame's plugins, but never managed to get it to work. His support isn't to great either.

  • Anyone?

  • Please have a look at the following image (created in Excel for explanation purposes) :

    I have a 11x17 grid. No arrays, but done with sprites (each block indicates a sprite). The user needs to build a pipeline from side A to side B, by tapping on the blocks. Tapping on a block 'selects' it, changing opacity to 60%. Tapping again on the same block, 'deselects' it by returning the opacity to 100%. Once a path has been made with selected sprites from side A to side B, the user clicks on OK button, and the 60% opacity sprites are destroyed, thereby creating the path. Also, the sprites each have the solid behaviour set to ON.

    What I need to do is to implement a check, before the sprites are destroyed, that the path is valid (as shown with the blue line in image). This check needs to pick up that the yellow line is not valid (due to the joint indicated in circle 1) or that the path is incomplete, as shown by the green line (circle 2).

    The selecting/deselecting of the sprites I've mastered, as well as the destruction of the 60% opacity sprites. But for the life of me I have no clue where to even start creating a check as described above.

    I would really really really apreciate anyones guidance or even just thoughts on how to tackle this problem.

  • ....

    Sorry. I got it to work today. Had a piece of leftover code undoing what I was attempting ( hint : it involved "Pick furthest" lol lol ), but I got it to work now. Thank you so much for your help!

  • For the other object, use layout.Width-object1.x and layout.height-object1.y to get the opposite location. (Or whatever width and height the total black area is, if your layout is bigger.)

    My second object keeps spawning in the bottom right of the screen using your suggested code. Any idea why?

  • Thank you! You got me thinking in a different direction. Overlapping shouldnt be a problem if I do this:

  • Can some of the skilled Construct 2 ninjas please advise me how to spawn 2 objects, at random points but on opposite positions relative to each other, only within the black area (as seen below) ?

Trent123's avatar

Trent123

Member since 30 May, 2015

None one is following Trent123 yet!

Trophy Case

  • 9-Year Club
  • Email Verified

Progress

10/44
How to earn trophies