Sushin's Forum Posts

  • I'm about to start making a mobile game and I'm wondering if anyone with experience can give me advice.

    Mainly I'm worried about screen sizes. I'd like my game to be fluid between 16:9 and 16:10 but i'm not entirely sure how to do that.

    I'm also curious how to accurately detect swiping and (preventing) switching between landscape and portrait mode.

  • You actually have to have each of the characters be placed on a grid. In your sprite font images it doesn't look like they are on a grid at all...

    After that, you just type in the width and height of each character box into the properties of the sprite font and they should appear.

  • Wow o_o I suggest you get an animation manager for each object.

    Instead of starting or stopping animations within other actions, create events that only pertain to the animations and make each animation happen in the order of importance. I'll show you an example from a game of mine.

    <img src="http://puu.sh/3OFFi.png" border="0" />

    This ensures that only one possible animation from this object can be playing at any given time, and you have all of the animations that will ever play for the object right in one spot. They will happen in importance from top to bottom, so if you have a falling animation, put that above the walking and idle animation.

  • I have a situation where I am referencing the same object twice in an event and action (using a family) and I only want to reference a single one of the objects, not all of them

    In this case, the code is "If object is overlapping object and object.x is less than object.x"

  • Try something like this:

    Object1 is overlapping Object2 and

    Object1.x < Object2.x, then

    set X of Object1 to Object1.x-1

    This basically moves object1 to the left (if its on the left side) every moment it's overlapping object2. You can do it for the other side (and should) by changing the negative 1 to a positive 1 and the less than to a greater than.

  • Compare X and/or Y, or compare distance() between two objects.

    If you use the distance formula, you might also have to do a for each loop because it won't register which enemy you want to run away otherwise.

  • The "On start of layout" event is a trigger. It can't be paired with an or operator because it always happens and is the soul trigger for the event.

    Other events that have a green arrow such as "On collision with" can't have the "or" operator either.

  • Well, if you are using the platform behavior for vectors, try removing some of the default values set by the behavior by setting them to 0.

  • Um...trust me, EaseTween is not the easiest way for such a simple action.

    But it depends on how you are moving the enemies in the first place. If you are using the platformer behavior then modify their vector by a value, which would look something like this.

    <img src="http://puu.sh/3Jvue.png" border="0" />

  • You could add the solid behavior to them

    Or , you could disable platform behavior when overlapping and re-enable it when not overlapping

    Thanks for the advice but neither of those really help me.

    The objects have to pass through each other because they patrol left and right via platforming. If I disabled the behavior of them when overlapping they would simply stop moving when they passed through each other.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi guys.

    I have platformer AI where the characters need to be able to go through each other, but one of the problems I'm facing is that they will bunch of against a wall when cornered by the player because they are trying to run away.

    The problem here is that several of them appear to become a single entity and it's very hard to split them apart even if the player leaves and they resume their mostly random movement.

    Does anyone know of an easy way to fix this issue? I'm using the platform behavior for their movement.

  • Make the transparent box visible and you might be able to see the problem.

  • There is a dotted box at the very top left of your layout. Everything inside that dotted box will not move if the parallaxing for the layer it's set on is set to 0,0.

    It's possible you put your hud objects outside the dotted box.

  • Can you even use that or symbol in construct? I didn't know that.

    Why don't you just make two conditions and set the block as an "or" block. Right click the block with the conditions and if one condition in that event is true then it will do the actions.

    If you want to do a "and" and "or" block, you have to make a sub event block for that unfortunately, but I'm certain it will work.

  • Add an else condition between the two statements.

    Problem:

    If pause 0, pause = 1

    If pause 1, unpause = 0

    You are effectively pausing the game and unpausing the game in the same action, because the events are read from top down.

    Adding an else condition to the second event will cause only one of those to be read per tick.

    Solution:

    If pause 0, pause = 1

    Else, if pause 1, unpause = 0