evillair's Forum Posts

  • Working on a small RTS pause-able space game.

  • Just make your first layout with everything you need and duplicate the layout. Or just generate a random layout each time.

    Perhaps others have a better idea?

  • Just use Go to layout by name and enter choose("level1","level2","level3","level4","level5")

    You just need to name your layouts correctly.

    Or you can have a text variable with that choose() and enter the level name there.

    This will load one of those layouts randomly.

    Use this (from the layout selector layout?) when you want to go to a random layout, change the names appropriately.

    So when you click your level one have 5 level names in there, for your level 2 add 10 names in there etc.

  • Great! Thanks!

  • The manual explains it pretty well: https://www.scirra.com/manual/150/containers

    "Containers are for making "composite objects", or objects made out of lots of smaller sprites (such as a turret and tank base making a single tank). Once in a container, picking the base also picks the turret, and vice versa."

    For example I have a enemy spaceship that have a lifebar, shield bar, shield and a trail all in a container, I just need to place the spaceship on the layout and all the others show up. I have a everytick that keeps them where they go. If I change the healthbar in an event they update for all the ships with the right values of the ships since they are spawned together.

    I never used them before, now after trying them out I use them on everything that have multiple parts.

  • Done, thanks again.

  • Hi Pulstar, I'm still getting islands with your latest one...

    Perhaps because I'm using too low number of nodes? I only need 10-15 max.

    Perhaps I broke something

  • Thanks Pulstar for some good ideas!

    Yeah, I learned quick to use naming strings for layer selecting

    Thanks again, it's appreciated.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Here you go, a close button: https://www.dropbox.com/s/s69f2qxvh3nlt ... .capx?dl=0

  • Have you tried using containers?

    Add all of the sprite that go together in 1 container. That way when you spawn one of those they all come along. You'll need to set the locations for each separately though.

  • Pulstar, that's cool! Nice work!

    99Instances2Go, yeah, that looks a lot easier! When I enter 10 for the variable How_Many_NODes I never get 10, I get a random amount under 10, am I missing something?

    A second question, how do I make this static once it's generated?

    For example, in a run of the game I would need to generate 10 of these on the start of the game and I would need access to these during the game.

  • Here's a tutorial for a pause button: https://www.scirra.com/tutorials/646/ad ... me-pausing

  • Oh nice!

    Would there be an easy way to limit the space between nodes? For example it would be nice to not have nodes close together.

    I guess you could just offset them if the distance of a line is too short?

    A second question, how do I make this static once it's generated?

    For example, in a run I would need to generate 10-15 of of these on the start of the game and I would need access to these during the game.

    I thought taking an image of them but that wouldn't work since I need the nodes to be clickable to select the map/mission etc.

    Example:http://www.blazinggriffin.com/wp-content/uploads/2015/02/Galaxy-910x512.jpg

    Each one of those nodes would be a generated map like you made.

    Thanks

  • 99Instances2Go, holy wow, nice!

    A clinic in functions!

    You're using a lot of things I haven't seen yet, I'll be studying this also! Thanks!!

  • wow thank you!

    That's quite complicated, I'll look at it and try and learn as much as I can.

    No wonder I couldn't figure it out

    For problem 2 I have a solution for it that I used before.

    Thanks again, I have a lot to digest!