oosyrag's Forum Posts

  • https://www.scirra.com/manual/119/touch

    You'll be using the Touch.Alpha, Touch.Beta, and Touch.Gamma expressions to get the tilt angle in degrees. Which direction do you want to tilt?

    For example, you can set the car angle by System - Every tick | CarSprite - Set angle to Touch.Gamma

  • Physics behavior - Apply force towards position. The position would be the end of the bungee cord/attachment/origin point. Use distance from object to origin point, the farther the distance the greater the force applied, to create the bungee effect.

    As for the bat, you can check collision or overlap between the bat and bungee object, then Apply Impulse Towards Angle. Impulse is how hard you want the hit to be, and angle you can use the angle between the bat and the bungee object.

  • OK couple more pieces of advice:

    I highly do not recommend using a program you are unfamiliar with to meet a time sensitive deadline.

    If you are new to Construct, try to avoid using plugins. You can do almost everything with what is included in Construct, and it will be significantly harder to get help on the forums if you use a bunch of plugins. People won't be able to open your file if they don't have the same plugins installed, and few people will go out of their way to install them to help you.

    Now about your project:

    Will each number always be tied to the same color? In that case, you should just draw the number as part of the sprite instead of using a text object.

    I see three main things you need to work on.

    First is preparing your tiles. As I suggested, you should create a single sprite object containing all of your tiles, with each number corresponding to the same animation frame. Set the origin point to the center.

    Second is moving the tiles. You mentioned dragging and swiping. These are two rather different things. Dragging would be relatively easy, while swiping could be rather hard. For dragging, you'll need to add a few instance variables to the sprite: boolean called Active, as well as an OriginXVariable and OriginYVariable to return the sprite back to its original position:

    On touched TileSprite | Set OriginXVariable to Self.X
                          | Set OriginYVariable to Self.Y
                          | Set Active to True
    
    TileSprite Active is True  |  TileSprite Set position to Touch.X, Touch.Y
    
    On touch release     | Move TileSprite to OriginXVariable, OriginYVariable
    TileSprite is Active | Set Active to False[/code:22ddonut]
    
    Third will be changing the tiles. You need to detect which two tiles are to be interacting (just using overlap will not work, as a tile can overlap several at the same time). Then you will change both tiles to the sum of their numbers/animation frame.
    
    Out of time for now, I'll be back with the third part later if you can't figure it out.
  • The particle object is limited. It is highly recommended to make your own custom particles using bullet and fade behaviors together. With families, you can also make much more flexible effects.

  • Well, there are a lot of things you asked to know how to do there, and a lot of parts to each of those things. Without knowing how far you've gotten on each part, you're basically asking someone to make your game for you. It would help a lot if you made an effort to try it on your own and ask a specific questions where you got stuck. If you upload an example of what you've got so far, it would also help in seeing what type of advice to give to you by showing your level.

    Otherwise... to start - I would use one sprite object for the tiles. Each animation frame should be a different color and value. The animation frame number can be the same as the value on the tile, so when you have two overlapping, you can add both tile's animation frame numbers to get your new number.

    Actually before that you probably want to figure out how to drag tiles around.

    So again, what are you stuck on?

  • What exactly are you trying to do with NW.js regarding setting the cursor from sprite action?

    If you post an example, it would be easier to help see what you're looking for or what went wrong.

    Edit: Does this work for you? https://www.dropbox.com/s/r56n1i0zegkaj ... .capx?dl=0

  • You cannot change the windows system mouse cursor. What you can do, as LittleStain said, is basically make your own mouse cursor by hiding the windows mouse and making your own mouse cursor sprite set to mouse.x, mouse.y every tick.

  • Try putting all objects in that layer into a family, and moving the family.

  • There is an action with the 8direction behavior - Set acceleration. You'll want to put an expression Touch.Gamma in here to get the Gamma, or your degrees tilt. Use math to adjust the final value to the speed you like.

  • Some quick experimentation with the example would show you that the bouncing behavior is based on the bounding box of the object.

  • Based on the difference between the timestamps, you'll know how much time was spent minimized. You can then use timescale to accelerate the game at a certain rate until the game has caught up. The faster the rate/higher the timescale, the greater the risk of bugs!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • https://www.scirra.com/tutorials/202/to ... put-method

    https://www.scirra.com/manual/119/touch

    The Compare Orientation with Alpha Beta and Gamma in the touch object is what you are looking for.

  • On the every x seconds event, add this condition for each object: System - Pick Nth Instance. Object is your Tent Roof/Floor, and instance is Self.Count-1.

    It might actually just be Self.Count or just -1, Sorry I don't have C2 available at the moment to test, but basically you want it to pick only the last created instance to move for that event. If it doesn't work try the others.

  • Hi Bio,

    There are a lot of tutorials and different methods that address the problem you are describing. Here is one example that I like - https://www.scirra.com/tutorials/4981/s ... den-player