Ashley's Forum Posts

  • Check out the Ghost Shooter tutorial on this page maybe:

    http://www.scirra.com/learn.php

    We don't have many tutorials yet... I'll try put together some more for the 1.0 release.

  • + Key W is down

    Add force 10 * cos(.angle), 10 * sin(.angle)

    + Key S is down

    Add force 10 * cos(.angle+180), 10 * sin(.angle+180)

  • [quote:35lcx7ap]Try to avoid using GLobal Variables. THey are slow

    I haven't seen any evidence to suggest global variables are slow; in fact, it's reasonable to expect them to perform faster, since they are in runtime memory and not wrapped by plugin code. However, this kind of micro-optimisation generally has no effect to improve performance, due to CPU/GPU parallelism.

    I'll write a wiki article on picking when I have time, it's a good idea I don't see how a 'picked group' is useful though, every object acts as a group of picked objects, because the actions only run on filtered instances.

    BTW, the system expression CountMatching can get the picked count.

  • I think your card is quite old and my best guess is it runs out of VRAM when the picture editor opens, which is the first thing that happens when you insert/double click a sprite, tiled background etc.

    Could you open a template and hit F7? It should show a VRAM report, something like:

    ---------------------------

    VRAM usage

    ---------------------------

    VRAM usage by Construct:

    8.34mb textures

    15.01mb targets

    23.35mb total

    Approx 707 MB texture memory remaining

    ---------------------------

    OK

    ---------------------------

    (I think the texture memory approxomation might not be in 0.94.3)

    I've had other reports of people running out of video memory on 64MB cards, but I can't work out why - the textures used by Construct should only add up to a few tens of megabytes.

    Also, it would be useful to know your screen resolution. It's possible turning down your resolution (eg. from 1024x768 down to 800x600) could help.

  • I still need to know your graphics hardware if you can find it out, for example nVidia GeForce 8800.

  • Can you throw together a quick example .cap? For Each triggers all the conditions below it, and actions and subevents, once per instance. It's a bit like saying "For i = 1 to Object.Count" and for each iteration, it picks a specific instance. Essentially, it is used to force system actions and conditions to work on a per-instance basis.

    For example:

    + On any key pressed

    + Sprite X < 320

    Create object 'ring' and position by Sprite

    In this case, when the event triggers, if a Sprite is left of X=320, only one 'ring' is created. The action is a system action, so simply executes one time. The ring is positioned by the first picked Sprite.

    Using For Each:

    + On any key pressed

    + Sprite X < 320

    + For Each Sprite

    Create object 'ring' and position by Sprite

    This forces the actions to be run once per instance, so a 'ring' object is created for every 'sprite' left of 320.

    Another use:

    + Compare values: distance(A.x, A.y, B.x, B.y) less than 100

    Destroy A

    In this case, because Compare Values is a system expression, it simply runs once, retrieving the values for the first A and B instances, calculating a single distance, and making a single comparison. This isn't useful if you have multiple A and B objects - unless you force the condition to check once for every combination of A and B:

    + For each A

    + For each B

    + Compare values: distance(A.x, A.y, B.x, B.y) less than 100

    Destroy A

    This destroys any A if it comes within 100 pixels of any B object, instead of only applying to the first instances.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • 'Every' events trigger without regard for specific instances, since they're a system condition. You can keep individual timers by subtracting from the instance's 'countdown' variable, which will work instance-by-instance. Note TimeDelta is the time in seconds since the last tick (the last time the event was run).

  • Just a note about bug reports: please make sure every bug you find goes on the tracker (link above). Even if you post it to the forum and I say I'll take a look, it would be useful if you also submit a tracker item. Forum posts get drowned out by the general discussion, and the tracker is an organised place to deal with all reports. Cheers! <img src="{SMILIES_PATH}/icon_smile.gif" alt=":)" title="Smile" />

  • So you can go file - new template, and open and run the templates? Is it purely inserting objects that crashes?

    It would be useful to know your graphics hardware - if it's onboard, the GPU model or just motherboard model, too.

  • Microsoft do do some things excellently - in my opinion visual studio 2008 is the best code editing IDE out there, and I use it for Construct. Also, while it's no more likely than a Flash runtime, a Silverlight runtime for web games is something to think about and research (but I emphasise, no more likely than a Flash runtime, which is pretty darn unlikely).

  • Are you drunk?

  • Haha, I think I forgot to add that condition

    I'll put it in the next build. You can also make all the rest of the events in the group a subevent to a "group is activated" condition - when it's done - saving you repeating the condition in every event.

  • Well, the activation of a group currently acts like a big 'if' statement. The activation state of the group is only checked at the top of the group, and if it is activated, all its events get run. Consider the event:

    + Global variable 'Myvar' = 0

    Action 1

    Set 'Myvar' to 1

    Action 2

    Even though the action 'Set 'Myvar' to 1' makes the condition of the event false, this does not cancel the running of the event; Action 2 is still run even though the event is no longer true. It's simply because the conditions are checked once only, and all actions are run when that check is true.

    The logic is the same with groups, and I'm not convinced it should be changed, since this behavior exists in other places in Construct. You could work around it by adding 'Group is activated' conditions to the subsequent events after a deactivate.

  • Sorry to spoil the surprise, but it's a helicopter.

  • Very nice solution, textures pull this off nicely. Kudos for scaling smoothness too!

    Hint: Enable 'Force Own Texture' on the circle layer, and add the Erase effect to the green circle. You get just a nicely antialiased black ring which might be useful.