mikehive's Recent Forum Activity

  • Hey all.

    I don't know how feasible this is, but, I'm wondering if it is possible to make a desktop game with nw.js that is able to download its own updates. I'm building a game that I think I would like to update a lot in the future, and I don't want to put it on Steam or anything.

    After much Googling the most helpful thing I could find was a forum thread from a few years back in which Ashley essentially said "you'll have to come up with something yourself."

    Is that still the case? Where would you even begin with that, if that was something you had a mind to do? Ideally I'd like it to work on PC and Mac, too.

    I'd really like to do this, but I haven't got the faintest idea where to start. Anybody got any thoughts to set me on the right path?

  • Yeah, I'm afraid you haven't quite got that right.

    You've got this:

    Player 3 > Is overlapping Player 2

    Player 3 > Is overlapping Player 1

    Right now, this event only executes if BOTH conditions are true. We don't want that (it's extremely unlikely that all 3 objects will overlap, so this will basically never run) - we want it to run if EITHER condition is true.

    To do that, you need to add "OR". To do this, right-click on the condition block and click "Make 'OR' block".

    That will give you

    Player 3 > Is overlapping Player 2

    OR Player 3 > Is overlapping Player 1

    :)

  • This is a bit difficult to get your head around but is very doable. It's kind of hard to explain so forgive me if this is difficult to follow - I'll try to make sense!!

    First of all, you'll need to have the player collision set up in the right way. For top-down games, you should ideally have the player's collision object set to be a small shape at the character's feet (like you are controlling their 'shadow'). This will allow you to easily keep track of where the character's feet should be in relation to the ground.

    "Jumping" in a top-down game is kind of weird to get your head around, but really, the player collision object doesn't jump - only their visual representation. In the first Startropics screenshot you posted, you can imagine that what you are really controlling is the guy's shadow, and the actual character sprite just moves up and down to look like a 'jump'.

    So, to implement jumping all you need to do is:

    1) Give the character an animation that looks like 'jumping'

    2) Add obstacles that the player's collision object cannot pass unless the character is in their 'jumping' state

    Is this making sense? 🤔

  • There are several different ways of doing this. For your purposes, the simplest way might just be to do an extra check after spawning to see if any player objects are overlapping, and if they are, to reassign them to a new square. You'll want to do this in a While loop to ensure you don't randomly put them into a different occupied cell. (This isn't a great idea if you have a very large number of player sprites, but for just 3, this should work just fine).

    Eg. On start of layout:

    -------Spawn Player 1 at random coordinates

    -------Spawn Player 2 at random coords

    -------Spawn Player 3 at random coords

    --------------WHILE Player 1 is overlapping Player 2 OR Player 3

    ---------------------Set Player 1 position to random coords

    --------------WHILE Player 2 is overlapping Player 1 OR Player 3

    ---------------------Set Player 2 position to random coords

  • Looks great! Glad you got it working :D

  • One thing I've done in the past is to use an invisible helper sprite with Image Points laid out in the formation(s) I need. Then you can just place that helper sprite where you want the enemy formation to spawn, and spawn a baddie at each one of the Image Points.

  • It doesn't have to be that complicated. All you need to do is randomly pick one of the 3 values to be a low range. You can do it with one event :)

    Why not set color to:

    choose(rgbEx(random(0,25),random(75,100),random(75,100)),rgbEx(random(75,100),random(0,25),random(75,100)),rgbEx(random(75,100),random(75,100),random(0,25)))

    I've tested this and I think it works pretty well :)

  • You can use spriteName.PolyPointXAt(index), spriteName.PolyPointYAt(index) for this.

    Also there is spriteName.PolyPointCount to tell you how many collision polygon points there are :)

  • Hiya! Here's an excerpt from the manual:

    Stop loop

    Stop a Repeat, For or For each loop currently running. These loops are system conditions. The rest of the event's actions and subevents will still complete, but the loop will not run any further after that.

    This means that in your logic here, the loop is stopped but Construct still executes the remaining sub-event.

    You need to restructure your events :)

  • Hmmmm. I guess maybe you could do something manually, like... I dunno. An invisible sprite overlaying the whole slope, and when the player is overlapping it + is on the floor you move their X/Y coordinates at a 45 degree angle, perhaps? 🤔

  • Chrome on Mac is actually the Safari browser, so consider checking Sfari's settings.

    Uhhhh... what? Chrome isn't Safari. Chrome is Chrome, Safari is Safari.

    In any case, I have looked through every browser & OS menu I can find and haven't been able to disable this behaviour. It really seems like a C3 issue.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • What the best resolution of the ViewPort Size for this kind of game ?

    Im using 16:9 / 854 by 480

    Can I use 16:9 / 426 by 240?

    You can use whatever you want! It's as much an artistic choice as anything else. Smaller resolutions will obviously perform better, but you may not like how things look at too low-res. It's a balancing act. Sometimes when I start a pixel art game project, I'll make a few test images at different resolutions to see what looks the best and what I'm the most happy with.

    if I increase to 1920 by 1080 , it will force me to have images larger than I should use in a small resolution correct ?

    Correct.

    I mean I want to have a game with a good performance , with nice resolution and that fit all devices .

    A noble goal, but you might find it's a good idea to get more specific about the devices you want to target. When you say "all devices", are you including mobile apps? You will likely have difficulty finding a resolution that performs well on mobile while also looking good on desktop PCs. And more to the point, few types of games are equally suited to PC, consoles, and mobile (most kinds of games work best on one platform or another). So rather than trying to please literally everybody, you may find it helps to pick one target platform and work towards that.

mikehive's avatar

mikehive

Member since 13 Jul, 2015

Twitter
mikehive has 2 followers

Connect with mikehive

Trophy Case

  • 9-Year Club
  • x4
    Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

11/44
How to earn trophies