dop2000's Forum Posts

  • Browser On Back button : System go to layout StartScreen

    Or you can open a menu, or pause the game or do anything else. But you can just tell the app to "go back" or "go home", it doesn't work like this.

  • Check this example, it loads 3 images into sprites:

    dropbox.com/s/oybhqgus121bas2/LoadMultipleImages.c3p

  • No, you can't scale the image inside the Tiled Background. That's why it's called Tiled Background.

  • I bet if you return to this code in a week, you will not be able to remember what all these sprites and UIDs mean.

    This is not how you should program in Construct! Use families, containers, instance variables. Don't use Pick by UID, it's rarely a good idea, and definitely a very-very bad idea in your case.

  • This is the most horrific Construct code I've seen in my life! You have over a thousand sprites and you don't name them? You have 150K+ instances and you pick them by hard-coded UID? I will have nightmares about this screenshot..

    I can see one definite mistake - you are trying to pick a different instance with a different UID in a sub-event. You can't do this. If you need to pick another instance, you first need to add "System Pick All" condition.

    Sprite pick by UID=1 : Sprite set Visible
    
    	System Pick All Sprite
    	Sprite pick by UID=2 : Sprite set Invisible
    
  • If you don't want your enemy to move while shooting, remove "Find path" from that event. Save player's position in a pair of variables. When player is no longer in line-of-sight, then find path to its last saved position.

    Another option is to set pathfinding speed to 0 when player is in LOS, and reset to normal speed when not in LOS.

  • Well, your event #7 is wrong. It doesn't affect one infected cell, it affects all currently infected cells, restarting Sine for all of them, changing scale back and forth...

    If you want every infected cell to shrink over time, use Timer behavior, or Sine/LiteTween (with a long period time). But you need to do for one created instance, not for all instances at once. You can start the timer in event 5 and 6, immediately after spawning the infected cell. No need for a separate event #7.

  • AllanR has explained you how to do it - set frame 0 on one sprite instance, load an image. Set frame 1 on another sprite instance (or pick an instance with frame 1), load another image. Repeat as many times as needed. Your sprite should have enough empty frames, and animation speed set to 0.

  • It should work the same way on Android. You probably have a mistake in your code, you need to post your project or a screenshot of events.

  • You still can add these objects into another family (one object can be a member of multiple families). But of course, you will not be able to access behavior properties if they are defined in different family.

    Maybe you can use "On created" event for each family to set some properties.

  • One way to do this is to add all such objects into a family. Then, after you created an object, add a sub-event "System Pick last created Family". In this sub-event you can change properties of the newly created instance, for example "Family set angle to 90"

    If you need to change behaviors or instance variables, you will need to define them 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
  • SpriteFont is an image. It will always look exactly the same on all devices. While Text object may be rendered differently, depending on the browser, installed fonts etc. There are lots of other differences - SpriteFont can be scaled smoothly, you can control the spacing for each individual character etc. And of course, since it's an image, you can add any effects to characters, outline, shadow, or even replace characters with pictures.

    For example, you can display a message "You collected 10 #", where instead of # symbol there will be a picture of a golden coin.

  • klabundee is right, in your example it doesn't matter when you set the boolean variable, you can set it in the main event.

    But in situations when you need to run an action after previous sub-events are finished, you have to do it like this:

  • Or something like this:

    On every tick
    For each Coin ordered by Coin.Y
    	Coin set x to lerp(self.x, Player.x, dt*10/(loopindex+1))
    

    Physics behavior is definitely not a good choice here.

  • I'm making gifs with GifCam tool - it's free and easy to use.

    blog.bahraniapps.com/gifcam