oosyrag's Forum Posts

  • Slingshot -

    Using 8 direction or platform.

    On clicked object, set object as selected by saving it's UID to a variable.

    On clicked released, pick object by saved his - set object vector and max speed x,y to difference in mouse position and object x,y.

  • Have you tried on a different computer?

    Doesn't seem like memory issue, collision checks are low.

    Any physics or loops?

    It could be some sort of CPU throttling from the OS, but that is unlikely.

    Total system memory use? Caching vram to page file could cause the symptoms you describe.

    Otherwise... do you have a lot of layered/invisible sprites? With a high resolution screen like that, you might overwhelm the fill rate limit of your gpu.

  • I made an attempt.... but failed.

    I'm not quite sure why, maybe someone else can fix/finish this.

    It kinda does work if you have each event separate rather than in a loop (activate the group, disable the loop). Must be some sort of picking/repicking issue but the answer evades me at the moment.

    https://www.dropbox.com/s/tnw6yorql2jio ... .capx?dl=0

  • Correct. But you can add conditions to specify on nth touch released to account for various situations.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • One more method! Math based, use modulo (%).

    x=156

    a=floor(x%10) = 6

    b=floor((x%100)/10) = 5

    c=floor((x%1000)/100) = 1

    But still first method mercury mentioned is probably most straightforward.

    mid(str(x),0,1)=1

    mid(str(x),1,1)=5

    mid(str(x),2,1)=6

  • Add a condition that checks the State of the arrow, or a variable that keeps track of it.

    For example, add an "IsFlying" boolean instance variable. When you shoot your arrow, set IsFlying to true. In your firing event, check to make sure Arrow.IsFlying is false.

  • Oops you're right, there are no quotes.

    [quote:9meuzx4b]X

    Y

    XAt(index)

    YAt(index)

    XForID(id)

    YForID(id)

    Return the current position of a touch in layout co-ordinates. It changes to reflect scrolling and scaling. However, if an individual layer has been scrolled, scaled or rotated, these expressions do not take that in to account - for that case, use the layer versions below. The At expressions can return the position of any touch given its zero-based index, and the ForID expressions return the position of a touch with a specific ID.

  • Add the mouse object. It has the ”on object clicked" condition where you can specify the sprite you want to be your button. Action change layout.

  • Are you talking about the multiplayer plugin? Follow the official tutorials, they cover everything you asked.

    For local multiplayer you need two set of controls. They should be under parent events with conditions that pick the correct car to control, such as an instance variable like you mentioned.

    As for your display windows, there is no way to help you based on your vague description without seeing what you have done in the first place. Post an example.

  • https://www.scirra.com/manual/119/touch

    Touch.Xat("1"), Touch.Yat("1")

  • Use a larger light radius on your shadow light object to render penumbras (only supported with WebGL).

  • Don't think it ever worked like that. Since X is the parent loop, the order will be

    0,0

    0,1

    0,2

    0,3

    1,0

    1,1

    1,2

    1,3

    and so on.

    Just swap x and y in the conditions. Also it doesn't need to be in a subevent btw, the two loops can go in the same event.

  • Its always been like this?

    X is "horizontal" (rows), y is "vertical" (columns).

    Because of the way the loop works, x then y makes columns. So the first loop, x=0, runs the y loop - 0,0 | 0,1 | 0,2 | 0,3| ... | 0,7 - after completing, the next x loop runs 1,0 | 1,1 | ... and so on.

    Basically when you have y as a subevent of x, each entire y loop has to finish per loopindex of x. When you take the x loopindex as the y coordinate and vice versa, the position in which they get placed gets inverted as well.

  • They are completely separate systems...