Zoltar's Forum Posts

  • How do I keep the same image object in the same place between two layouts ?

    I have an image which is located in layout 1 in some position(x,y), when the game goes to another

    screen, which is layout 2, I want the same image to be on the same spot regardless of other objects in

    the second layout.

    Is there a way to do it by an event on layout 1 so it will affect also layout 2, without using the same

    event to position the image also in the events sheet for layout 2 ?

    For example, like a life bar you see between different screens/levels in a game.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I need to store an image in array, so the value to store in array is:

    X: 0

    Y: 0

    Value: image_name.???

    How should I type the value since the image object name alone is not enough ?

    Thanks in advance.

  • Wowww thank you, it was very quick, works like a charm

  • How do I destroy an image object which is behind another image object and without using

    the name of this image object ?

    For example, I have an image of a RifleSight object and behind it I have an image of a victim.

    When I touch the Fire button I want the image of the victim to be destroyed but without referring the name

    of the victim image (since the victim image may change dynamically).

    Is there a way to refer somehow to the layer behind the RifleSight object or maybe the Z position ?

    Thanks in advance.

  • Hi,

    In order to explain the problem please load the file I provided:

    When you run the project in the browser you'll notice that every time you press on the

    "RollDown" object (down arrow image), then the "Focus" object moves down from Cell1 to Cell2 and etc.

    which is ok for running it in the browser.

    The problem occurs when I export to run it on Android, then in my Samsung Galaxy S2 the "Focus" object jumps

    from Cell1 to Cell3 and etc. (2 cells for every touch on the "RollDown" object).

    I tested it also in the IntelXDK emulator and the same problem for every device I tried.

    I've managed to fix the problem by changing the action of the event to: Set Y to Focus.Y + (Focus.Height / 2)

    but then when you run it in the browser the "Focus" object moves down half a cell each time while in my device it moves

    each cell ok.

    I don't understand why I should change the action of this touch event to this: Set Y to Focus.Y + (Focus.Height / 2) while

    this: Set Y to Focus.Y + Focus.Height is the correct one that should be, can someone explain it please ?

    Thanks in advance.

  • Ohhhh, thank you, how I didn't thought about it before ?

    Works like a charm

  • Hi,

    Is there a way to convert dynamically (in real-time) integer numbers to sprite-font ?

    I have a global int variable that I want to display it's value with sprite font every time it's value changes.

    Is it possible to do that without using web font ?

    Thanks in advance.