LittleStain's Forum Posts

  • Delete what is red and add the green bits..

    [attachment=0:rlvqjjaj][/attachment:rlvqjjaj]

  • This tutorial covers the basics about that..

  • There are (probably) some issues with your capx..

    Even with 7 FPS you should be able to have a look at the debuggers info to see where that is coming from..

  • What kind of behaviour are you using for the movement of the bird?

    sounds like you want something like:

    Bird if x-position < 100

    -Bird set mirrored

    Bird if x-position> 400

    -set not mirrored

  • All your events are being checked all the time.

    what you should do is something like this:

    Give the enemy an instance variable Health

    enemy : variable Health =< 0

    • enemy destroy

    On enemy destroyed

    • system subtract 1 from varlifehearts
    • LifeheartTiled set width : varlifehearts*24

    Are all your enemies different sprites or are they the same enemy cloned?

    For if they are cloned, I would recommend using copies rather than clones so they all respond to the same actions. (I'm assuming you don't have a paid version, for if so you could use families for that)

  • Using the Debug-mode you can see what takes the most amount of processing time and memory etcetera..

    You could (read should) use that to find out what the bottleneck is..

    You should be glad it doesn't crash on windows, for that will give you enough time to figure it out..

    First thing I would look at is if there aren't objects being created all the time and if the collisionchecks aren't too high.

    It could also just be a part of your programming (events) that is taking up a lot of your cpu time.

    This is exactly what the debugger is for, debugging..

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • So many events that coulde be replaced by:

    LifeHeartTiled set width to: varlifeHearts*24

    I guess all enemyhealth global variables are the health for enemies on the layout.

    wouldn't it be easier to make that an instance variable and add 1 to varlifehealths on enemy destroyed?

  • I'm not sure what you mean..

    Ofcourse you can hardcode the laser size, but then it would just be easier to do it based on position rather than overlap, because if you shrink when not overlapping, it will never overlap again. Ofcourse using overlapping at offset could be of help in this situation, so maybe go there?

    If youd like you could try and use the line of sight behaviour, but I think it's overkill for this situation.

    What is "wrong" (not working for you) with the example provided?

  • I'm guessing not all wardrobes will be worn at the same time, so there's no need for all of them to be on the layout..

    I guess I'd put the wardrobes as seperate sprites on a seperate layout and only create the one needed through events.

    Would that work in your situation?

  • There are as always very many ways to go about this..

    Here's a very old but working example by R0J0hound

    It's for rotating lasers, but will work for this purpose too..

    http://dl.dropbox.com/u/5426011/c2/laser.capx

  • I'm also not quite sure why you'd need the pick nearest and the for each bird conditions, they don't do anything usefull here, I guess..

  • Use an instance variable on the bird instead of a global variable..

  • I'd be glad to help if you could give more information..

    Would creating a sprite which detects overlap at an imagepoint on the end of the sprite help?

  • Three questions:

    1. Why 100 small objects, there must be an easier way..

    2. Why is the z-ordering important? Would using animationframes work for some of the objects?

    2. Would containers work for what you are trying to do?

  • Sounds pretty straightforward:

    if player.x < enemy.x - enemy move left

    if player.x > enemy.x - enemy move right

    if player.y < enemy.Y and enemy is over ladder - enemy climb up ladder

    if player.y > enemy.Y and enemy is over ladder - enemy climb down ladder

    probably should have some stuff happen when colliding with walls and so on, but seems to me these are the basics, right?