Asmodean's Forum Posts

  • The box has to touch the floor, then it worked.

    I made a better example:

    http://superintendant-horse-41852.bitballoon.com/

    This should work.

    CAPX:

    https://drive.google.com/uc?export=down ... kU5bzVEVEU

  • I would use gravity and Vector Y, something like this:

    This is only an idea. If you use helper-sprites like mercuryus said, you could change the immersion. Maybe that looks nicer.

  • Maybe I'm wrong, but as far as I know Jimdo is more a construction kit for websites. You can choose templates and then fill it with your own content. Like a CMS (Content Mangment System). So I don't think it's possible to upload you own html5 webside.

    If you are looking for an easy to use webhoster for your Construct 2 games/apps try bitballon. It should be pretty easy to use. https://www.bitballoon.com/

  • Try:

    Use for 'X < a < X2' in System 'is between values'.

  • Try

    NWjs | Run "start c:\""first folder\second folder""\batch.bat"

    or with a folder in between without space

    NWjs | Run "start c:\""first folder""\folder\""second folder""\batch.bat"

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Click on the events tab (the events ribbon on the top), on the left there is "Show 'add action' links.

    Events Tab: https://www.scirra.com/manual/38/ribbon

  • I have a very hard time absorbing anything I read in a book unless I am following an example in the software.

    I have the same problem. I'm trying to make an little example or if it's possible to split the problem in tiny pieces and make for each a little example to look what happens. For this it's necessary to use the debugger or use a text-object and put the values in it. And there is always help in the forum here. <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

    [quote:20rguqpk]

    I understand the coordinates all come from top-left. That is why the ViewportRight(0) threw me, because far right would be 1920. So the "0" means nothing basically? I am still a little confused. ViewportRight is telling it the far right edge of the viewport then? I was unaware the viewport is on a layer. So that is confusing me I guess.

    Don't confuse layout with the viewport. I made a litte example:

    https://drive.google.com/uc?export=down ... 2t4aU5jQW8

    In this example you have 8 Direction movement. You will see the coordinates of the object (green square) and the boundary of the viewport and Vector X and Y of the object.

    The layout has 1708x960 pixel the viewport (window-size) is 854x480. If you move the object you will see that the coordinates will change but if you subtract ViewportRight from ViewportLeft it will always have 854 pixel, the same with Bottom and Top this will always be 480 pixel. In this example I use the name of the Layer in the Viewport Viewport("L2"). As long the Parallax is not changed it is regardless of which layer you use or if you use the name or the number of the layer, so it is regardless if you use "L1" or "L2" or 0,1, in this example.

    Try it out and I hope it will do more help than confusion. <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

  • Thanks a lot. That helps. There are so many ways to do things in this program I never know what to do. It would be nice if someone made a tutorial on various movements and explained why to use one over the other. It's all fairly confusing to me.

    I can only recommend to read the manual. It's really worth to read, most of the questions are answered there.

    [quote:74c7vlvb]

    So help me understand this...

    For the viewport borders you are comparing the player's positions. "If X > ViewportRight(0)-PLAYER.Width/2-1" tells this event if the player gets within 1 pixel of touching the right side of the viewport to set the 8 direction vector X to 0 correct? I watched this in debug and it helped me understand it better. This is based off the player origin point right?

    This is exactly what it does. The player origin is a very crucial for this. If you have an animation where the origin is on different positions, you get a bug that is very hard to track down. If you use this kind of condition.

    [quote:74c7vlvb]

    ViewportRight(0) - I think I see what this is doing. So Viewport[direction](X) tells it to take the position from the viewport edge in the direction specified (X) pixels from that edge?

    Not exactly. The x is only the layer of the viewport. If you have different layers you can change with 'Parallax' in the Layer-Properties the scroll speed. So the viewport can be on different position on different layers. I could have used Vieport("BG") instead of Viewport(0), it's the same.

    The viewport itself is only a window of the layout what you see. You can scroll the viewport around in the bounding of the layout. The size of the viewport is the size of 'Window Size' in the 'Project-Settings'. In your example if you use the 'Test_Layout' the Layout and the viewport has the same size: 1920x1080. So in this case there is no scrolling. All Layer have the same viewport position. ViewportLeft(0) is X=0, ViewportRight(0) is X=1920, ViewportTop(0) is Y=0, ViewportBottom(0) is Y=1080. But the position of the Viewport depends of the scrolling in the layout, so the Viewport values are NOT always 0 and the window.height / width.

    Another crucial point is that the origin of the coordinates are top left. Maybe that will help to understand the vector X and Y a little bit better. I set the Vector X or Y to zero if you are on the border of the Viewport and you have the velocity to this border, otherwise you couldn't fly in the opposite direction. The velocity would always be 0 if you are near the boundary. So if you the gravity drag the object down you get a positive vector y, because of the coordinates.

    My example should also work if you scroll in a bigger layout, because with the 'ScrollTo-Behavior' the object is always in the center of the viewport. The exception is when you got to the boundary of the layout, then the object should move to boundary of the viewport.

    My english is not the best, I hope that makes all at least some sense to you.

    Please ask if something isn't understandable.

  • You have to make borders that you can set the speed to 0 in this direction if you come to the end of the layout. In your case there are no sprites that can be used as borders. So you have to make virtuell borders. You have only to look if you on one end of the layout. I change your example a little bit to show what I mean.

    https://drive.google.com/uc?export=down ... C1XeElrR3c

    Please feel free to ask if it's not clear what I'm doing.

  • The problem is you have a max speed of 600, but only a acceleration of 125 and declaration of 75. If you now are going to the left and hit the left boarder with full speed and now you want to the right. The speed has to decrease from 600 to 0 and this takes its time, because of your acceleration before you can go to the right. The same is for right and the top. The bottom is a little different. You are using the Bullet-Behavior for gravity, but the gravity increase over the time, even if you sit on the bottom. So if you wait a little the gravity is over the max speed and you can not move anymore. You can see that if you go in Debug-Mode and look on the gravity of the Bullet-Behavior.

    You shouldn't mix so many moment behaviors. If you want use the physic-behavior you should use only the physic behavior, and the physic-behavior doesn't like the solid-behavior. So you have to be cautious what behaviors do you use.

  • Have you tried Letterbox scale instead of Letterbox integer scale in the C2 settings?

  • Do you use 'Is by wall' from the Plattform-Behavior? Wouldn't that be easier than to check for x and y coordinates?

    However, I made something with ' is overlapping by offset'. Maybe it's helpful for you. I shows where the sprite has its collision.

    https://drive.google.com/uc?export=down ... EhIMXQ1N0E

  • Did you use 'push out solid' from the CustomMovment?

    If that doesn't work and your player stuck in walls you could use the reverse-action from the CustomMovment when overlapping the wall.

  • You're welcome. What was the problem with this error? I had someone too with that problem. How did you solve it?

  • Something like that?

    https://drive.google.com/file/d/0B5FlDY ... sp=sharing

    The Player has 8Direction-Behavior, but that should not really matter.