dop2000's Forum Posts

  • Use an instance variable - once the sprite is spawned, set a value in the variable. Check that this value is not set before spawning.

    Another option is to add the child sprite to a hierarchy. Check that the parent sprite has no children before spawning.

  • but after 180 angletoplayer variable becomes negative

    It doesn't matter if you use special conditions which deal with angles - like "Is between angles", "Is within angle".

    Also, you should use delta-time if you need to rotate or move characters with events. Replace "rotate 1 degrees" with "rotate 60*dt" degrees.

  • You can use angle() expression and "Is within angle" condition.

    For each enemy
    System enemy.angle is within 20 degrees from angle(enemy.x, enemy.y, player.x, player.y)
    ... Enemy spawn bullet
    
  • but now one time.

    I don't understand what you mean.

  • There is no bug, you just need to configure all settings properly.

  • Because it doesn't work per instance. If var=2 condition is true for one instance, the event will run once for it. But if var becomes 2 for another instance, the event will not run again, because it has been triggered once already.

    Like I said, it's a very common mistake, I've seen it so many times. Scirra devs really should've explained it better in the documentation.

  • Don't use "Trigger once" when multiple instances are involved. It's a very common mistake, which can cause all kinds of bugs.

    Simply put the "find path back home" action after 3 seconds wait.

    Enemy on arrived
    pathtype=1 
    ... Wait 3 seconds
    ... Enemy set pathtype to 2
    ... Enemy find path to home
    

    Or, better yet, use Timer behavior instead of Wait.

  • Try making the preview window larger. When it's smaller than the Viewport Size specified in project properties, all graphics is scaled down. When 1px lines are scaled down, they will always be distorted.

    Try these settings, they work for me:

  • Click Menu->About

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Your spaceship sprites are scaled down by default on the layout. So when you set their scale to 1, they naturally grow to their original size.

    Change the formula to something like this:

    Spaceship set scale to clamp(0.5+(Touch.X-ScaleX)*0.0090, 0.3, 1.5)

    I also suggest using hierarchies instead of Pin behavior.

  • In project properties change Fullscreen Mode to "Letterbox", then change Fullscreen quality to "High".

    If you want, you can then set Fullscreen mode back to "off", although I don't recommend this.

  • I believe you have a mistake in event #2 - you want to change animation to "plant" there, not "plant_dry".

  • Check out this demo:

    howtoconstructdemos.com/zoom-a-sprite-or-entire-screen-with-pinch-touch-gesture

    There is also an official example:

    editor.construct.net

  • Not sure what you are asking. Try changing some project properties - sampling, fullscreen quality etc.

    If you need to resize the rectangle and you want its border to always look the same, try 9patch object instead of the sprite.

  • You don't need to create a new event sheet for every layout, multiple layouts can share one sheet. If you don't assign a sheet to a layout, then no events will be running.

    You can also have event sheets which are not assigned to any layouts. And you can include event sheets into other event sheets.