Aphrodite's Forum Posts

  • It may be a stupid suggestion, but instead of having the for each inside the function, maybe have it outside, before calling it

  • Normally a for each ends like.. this (since Events are read from top to bottom):

    And a function is over.. well juts after it's done, I do not know how to explain really, since the function isn't done in parralels, you call the function, it executes it, then it continue where it stopped previously, like if you just pasted the function inside an event (however functions and wait do not mix up that well it seems).

  • orugari :

    C2 isn't a 3D engine, so indeed you cannot spin around axis other than Z, however, you can simulate the other rotations, IF you only rotate one of them at a time

    exemple: https://dl.dropboxusercontent.com/u/100 ... index.html

    You might be able to simulate Z + one of the others, but not sure about that

  • Can we have a screenshot of the concerned events then?

    Also:

    "System - Pick Eggs by evaluating Eggs.UID = GameFunctions.Param(0)

    System - Pick Basket by evaluating Basket.UID = Eggs.BasketUID"

    you can do :

    Eggs - Pick by Unique ID : GameFunction.Param(0)

    Basket - Pick by Unique ID : Eggs.BasketID

  • Did you included the event sheet containing the function and the one containing the call? (Not saying you are dumb, but more than half the time, it is the issue it seems.. I do that a lot too ^^"').

  • lennaert

    >

    > > Hi.

    > > I tend to split my dedicated layouts now, objects, characters, etc. with a result indicating much lower estimated memory usages for the biggest layout (likely the layout filled with most unique objects/animations)

    > >

    >

    Where can i find more info about this?

    I will go through a re-sizing exercise and re-size all my assets appropriately.

    [quote:1j2sb8bs]Construct 2 displays an estimated memory use in the status bar. You should keep an eye on that. The estimate is based on the largest layout's image memory use, plus the memory used by two images the size of the window (which will probably be necessary by the OS or engine rendering system). With good image re-use, it should be easy to keep this under 60-80mb.

    This is what is showed in the status bar, however, a more "legit" value would be by using the ImageMemoryUsage system expression, which will return the current memory use of the images currently loaded (which can help compare layouts memory use of images, to see if one of them is using a lot compared to others).

  • You do not have permission to view this post

  • Hey guys,

    Long time lurker, first time poster.

    I've built a patform game and I've just implemented health pickups.

    Throughout the game you acquire hearts which add to your overall health.

    Problem - When I 'pickup' a health potion, I can't figure out how to add to the health depending on how much

    the player has acquired.

    Ie; If the player has 6 health, but the potion gives you 3 and the player has a max 7 health.

    How do I make it so theplayer only gets 1 health from the potion, making player health variable not go

    over max health 7?

    I hope explained that properly ! I have two variables, player health - the variable governing enemy damage, death and the darkening of acquired hearts.

    And Health Marker variable, the variable governing how many hearts are acquired.

    Please help I'm finally stumped :8

    When you acquire the potion, do this:

    Player: set health to clamp(Player_current_health+normal_quantity_the_potion_will_regen, 0, Player_max_health)

    See the manual for more details on the clamp expression: https://www.scirra.com/manual/126/system-expressions

  • Heyo,

    In construct 2 we have access to box 2d physics. Within this realm we can either chose to have a body that is dynamic (reacts to collisions) or static (doesn't move). There is a third type of body available in box2d that I need and perhaps you do to: The kinematic body. This is a hybrid body that can have a linear velocity but that is unaffected by forces acting on it. In other words, it can move but cannot be moved by other objects. Ever wanted to have a moving platform using physics but gave up because every time the player jumps on it it gets thrown off course? A kinematic body would work well here, but all that you can have in construct 2 is dynamic or static. Not every object that moves needs to be moved by other objects. Check out the link below for a short sequence of code demonstrating its uses and a short explanation.

    http://www.emanueleferonato.com/2012/05 ... ic-bodies/

    Ashley Is there a way to bring this functionality of box2d into construct ? I know there was limitations in the box2d version optimized for javascript /html5 (you can't disable collisions- Why is this btw?. Having collision masks would be super helpful). Is this perhaps the same with kinematic bodies? Is the code for this body type already in construct, it just doesn't have editor support?

    if you control a set 'Immovable' object by events to move it, wouldn't that do the exact thing you want?

  • First apply the damages to the health, then set the healthbar width to 20*( healthpoints/100)

  • If webgl is on (or on ejecta), everythkng is loaded layout by layout, you could maybe if there is no better way have a layout that does nt at all use that.

    Also each webgl effects can be deactivated, you should have a way to turn them down via a variable.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I think Node Webkit is basically having all files inside the executable (not sure but renaming the node webkit exported executable into a .zip can open it and show the files, like they are just added together), so if your first index.html can link to others in subfolders, I think it should work

  • You could put the NoSave behavior on everything that does not need to be saved, or you could build your own save system using webstorage

    Since the save built in c2 is a save state, everything without NoSave behavior should be saved and loaded

  • 30 fps logic could in theory have twice more time to be calculated, also, since C2 doesn t render the screen if nothing has changed, it effectively would make less rendering work from what I understand

  • Even though I do not think Iframe embedding is a correct solution, if all the games are stored at the same domain, you could try to use the webstorage (session storage) to achieve that