Yann's Forum Posts

  • little correction, r0j0's capx left a coma in front of multiple of 3 length numbers.

    comaNumbers.capx

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • nope, fx are for construct classic

  • It depends what "quitting the game" means to you. Closing the browser window?

  • Nifflas did such thing. His solution was to create a level editor. The basic idea is that the whole game world is in an array and the game constantely keep track of your position in this whole world.

    Then you just have to update the display (destroy all scene object, create and place the corresponding sprite for the next room) each time you change room. As you know the position of the hero in the whole world you can position him accordingly in your room so transitions match.

    But yeah... Level editors aren't easy.

    http://nifflas.ni2.se/?page=Knytt+Stories

  • add a boolean 'active' with default true to your sprite buttons

    +System: Every Tick
      -> Button: set active to true
    +System: Layer "yourLayer" is visible
      -> Button: set active to 'false'
    +Mouse: On left click on Button
    +Button is active
      -> System: set Layer "yourLayer" to visible
  • that's how I would do it zoomCycle.capx

  • Weishaupt

    if the player overlap the sprite, every tick you do a lerp(currentOpacity, 100, 5*dt)

    (forget the min and max function they are useless... just to scare some n00bs)

    basically while you are overlapping the sprite, every tick you travel a little percentage of the distance between your current Opacity and 100.

    But this percentage is fixed and is equal to 5*dt.

    So as the distance decrease, the same fraction of this distance decrease, so you basically ease in the value

    the primary goal of lerp() isn't to be used like that. You usually have a starting point, an end point and a percentage (from 0 to 1)

    so you usually do lerp(start,end,percent) and you make the percent value evolve to create movement.

    But here the percent is fixed and you apply the result of the lerp to the start value, so the distance between start and end decrease... etc I explained that already.

    And you do exaclty the same when you don't overlap. But toward 0 instead of 100

  • between 00h34 and 00h43 why ?

  • in two events yeah

    shortFade.capx

  • You don't need to do all that, When you edit your animation you already have a bunch of properties in the property panel (click on the name of an animation you'll see)

    You can set a default speed and some looping properties.

    So basically you just need to

    +Button: on clicked
      -> Set animation to "what you want" (start from begining)

    It should play the animation you set and loop it if you set this animation to loop in properties

  • Actually CC is quite a good engine in my opinion. Indeed a few bugs, but once you know them you can avoid them pretty easily.

    Also there are a bunch of pretty good plugin for CC. And I think at the moment C2 hasn't caught up with all of CC's feature yet.

    In short, I don't think you wasted your money.

    Well, I don't know much about the quality of the ebook. There's no official ebook for cc as far as I know.

    And yes, CC and C2 are very similar, so learning CC isn't a waste of time 'cause C2 works the same way.

    So enjoy (:

  • Global number direction=1
    Global number rate = 1
    Global number step = 16 
    +System: Every rate seconds
      -> Invader: set X to X+step*direction
    +Invader: X > LayoutWidth-20
      -> direction = direction*-1
      -> Invader: set Y to Y+step
    +Invader: X < 20
      -> direction = direction*-1
      -> Invader: set Y to Y+step

    For the invaders movement should work

  • The problem you have comes from the fact that you have 2 Respuesta object on your layout: the one you placed at edit time, and the one you create on collision with Aciano.

    As there's no way to know which one to pick, c2 pick the first one.

    The solution:

    on start of layout -> Respuesta: Destroy

  • multiply is a pixel shader effect... hardware accelerated... so not yet (:

    to colorize a sprite there's no easy way.

    You could use a sprite with source-int effect but it will basically paste its texture on what is underneath it in the same layer (layer set to force own texture = yes)

    check this for what effect does http://www.nihilogic.dk/labs/canvas_sheet/HTML5_Canvas_Cheat_Sheet.png