Nifl's Recent Forum Activity

  • I'm not sure I understand, are you trying to make something like this?

    https://drive.google.com/open?id=0B3l68 ... 19ldk5rYkk

  • Debug-mode always lags for me. Does it lag without debug-mode for you?

  • The effect "Color" applied to an object over the colored one does this.

    Example: https://drive.google.com/open?id=0B3l68 ... zU4NWdjbk0

    Have a good day.

  • Thats you for taking the time to help randomly. (That's a nice sentence <img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing"> ).

    The first example can't account for collisions properly, due to it setting position. (And also didn't have the "Thrusters in space" feel to it.)

    The second movement sometimes didn't move at all for several seconds and didn't hit the cursors position.

    So I couldn't adopt any of those movements directly.

    But I did get a few ideas and learned a few things from them though.

    For starters, even though I had read the whole manual, I had never actually used lerp, and then I guess I must have forgotten about it, Because I just recently "Solved" this by using something like (A*C+B*D)/(C+D) instead of lerp. <img src="{SMILIES_PATH}/icon_lol.gif" alt=":lol:" title="Laughing">

    Experimenting with your second movement made me get the ideas that I then used to manage to build the movement I was after. In the end though. I systematically replaced all the lerp stuff I had in it. But it was an important stepping stone.

    I provided the "finished product" that I will implement into my game. In case anyone is interested.

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

    Thanks again! <3

  • Hi all! :]]

    I don't know if this is even possible. But I have thought a lot about it, and I can't seam to figure it out, so I thought I might ask if anyone else can.

    I'm making a game where you control a spaceship, and I want the spaceship to Follow the cursor around when the mouse is moved.

    Like a Bullet behaviors that has an event that always sets angle to Mouse.X and Mouse.Y.

    Also I'm aiming towards an "Asteroids"-feel to the movement. Meaning that ideally, the ship should accelerate, and decelerate smoothly, and if the cursor is moved, the ship should adjust to the cursors new position. Sort of like a custom movement which has an event that continuously accelerates the ship towards Mouse.X and Mouse.Y.

    On top of this the ship needs to adjust as to "hit" the cursor. All I can make it do is fall into an orbit around it. (which makes sense considering I don't know how to compensate for current speed and angle ).

    If this requires very difficult math or something, I'm willing to google around and try to understand your calculations. But I can't for the life of me figure this out.

    Any help would be greatly appreciated. Even as to say that this can't really be done. Then I would at least be content in giving up.

  • HELLO ALL! :]]

    Im making a platformed in which active objects will make up walls.

    When I place the 16 x 16 square sprites next to each other at a distance of 16, (leaving exactly 0x and 0y space between them) Construct claim that they (the sprites that are square) overlap.

    How can I make something that works like: a "grid" of 16x16 sprites with collision-boxes at 0,0|0,16|16,0|16,16. that are not overlapping each other?

    I want to make the player able to move the sprites, so as to (for example) clear a path for walking through with a 16x16 player, while still making the sprites look as though they are positioned exactly side by side.

    This is a cap demonstrating the overlap. Ideally the sprites shouldn't overlap.

    http://s000.tinyupload.com/?file_id=060 ... 6977932200

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Easy 1 event toggler for when you want two different values that can be tested for.

    [Condition (for example when pressing a key)] -> Set variable (the variable that you want to toggle) to variable - variable*2.

    This will make it so that the event toggles the value between negative and positive.

  • Thanks for replying!

    "Why do you use accelerate in a triggered event?"

    Hmm. I hadn't thought about that. I don't in my actual game.( I made the capx to illustrate the inconsistency of using the accelerate). So, accelerate can't be used to "set" the speed of an object, without having it act up?

    If this is how it works. I guess I'll just have to make a mental note not to use triggers with accelerate.

    "Wouldn't setting the speed to something different be better when only done once?"

    Well. I wan't to make it so that I can accelerate every other object every tick according to an instance variable of another object, which I then reset. I have in these 24 h realizes that simply isn't the best way to do it. I now have the game setting the speed of all other objects to another object every tick, and having that object accelerate instead.

    I think accelerating would work better if done for a certain amount of time..

    Yes. It seams to work if using lower values over more ticks. I can't help but feel that it's still not consistent, and that bothers me...

    Ah well. I think I have solved my problem though. Even If my questions still aren't resolved.

    I thank you for taking the time to read, looking at the .capx and replying!

  • Hello all! :]]

    I'm having trouble with the "accelerate towards angle" action. It seams that it doesn't work if used on an object created in the same tick.

    Also. It seams that accelerating objects is somewhat random.

    I included a simple capx if someone would be so kind as to attempt to help me sort this out.

    https://www.dropbox.com/s/dcus6r4d9ev05 ... .capx?dl=0

    Background:

    I'm making an "asteroid"-type game where you (a sprite with an animation of a space ship) is situated in the middle of the screen.

    When you press arrow keys to move, you stand still, but everything else moves around you.

    I have made my own movement for the ship. But moving diagonally makes the universe around you move only 0.5y and 0.5 x for every 1x/y you would move straight horizontally or vertically, making the movement not realistic, as a diagonal move would move you something like 0.75 in x and y in reality.

  • Well, thanks for taking the time everyone, (Have been afk over 9/11). I greatly appreciate your thought about and knowledge into the subject. I'm going to create a secondary object to test for line of sight now. Lets see how that pans out. If it doesn't work, well then I'll probably deal with this at a later time. It is taking to much of my creation time at the moment. Thank again everyone :]

  • Thanks for taking time helping me. I downloaded your cap file and tested it. It worked (of course :] ) and that great. The problem isn't solved though. I may have been unclear in what I was trying to achieve. Ill try to explain better.

    I have 1 player object (Call it "PlayerSprite") which i need to test Line of sight to objects from and I have 1 object which acts as both walls and enemies (Call it "Wall&EnemySprite").

    I need to be able to test if the "Well&EnemySprite" can be seen by the player.

    Now this, you solved if I were to have another object blocking the vision but the problem is that I need to know:

    Is any "Wall&EnemySprite" blocking the line of sight to any other "wall&EnemySprite"?

    That is:

    What "Wall&EnemySprite"s can the "PlayerSprite" see, and what "Wall&EnemySprite is blocked by other "Wall&EnemySprite"s?.

    I don't know how well I explained it, but I really only have 2 "Active objects" in the game; a PlayerSprite and a sprite representing enemies AND obstacles. (And I need it that way, as walls need to change to enemies and vise verse in my game)

    I Also should say that its kind of grid-based. It's a large chess board so to speak, with each "wall&enemySprite" having a huge number of private variables defining them, Including Alive,Mechanical,Ethereal and Enchanted each together deciding if the object is capable of acting as a NPC or if its "Dead", acting as a wall...

    Again thanks for the help, I understand that I'm not representing an easy problem, and than the solution may be to hard (or nonexistent in construct). But I really don't need a Super solution, only a frame-rate over, say 20, as its turn-based. All I need is to be able to play the game on slower PCs with that sort of stable frame-rate. :/

  • > Even if it was, It kills the frame-rate.

    This has been answered just a few weeks ago. There is a bug in the LOS behavior regarding objects with instances. The workaround is to use a family instead of the object itself (Just put the object into its own family).

    Thanks for the response, but I tried that already. It doesn't work for me. I have 1 player object and hundreds (some times) of "non player objects". If I use Families, I can't get the LOS behaviour to work at all.

    I wan't to make objects obscure each other, so that the one in front of another is obscuring it. Just can't get it to work :(

    And JayJay, the system you made was very interesting and "kind of worked". It seamed however that once an object gained sight of me, it continued to be able to see me, even if I hid behind the "map". Also it became very laggy once i reached about 100 objects (Yeah I know, 100 objects is a lot, but that's the problem, the player needs to be able to interact with the world very well, therefore I can't just make static Background object, or sprites with no LOS).

    Well, I feel than I have complained a lot. Maybe there is no way to be able to measure if you can see objects (with one hundred of them) without lagging. <img src="smileys/smiley19.gif" border="0" align="middle" />

    Thanks anyway guys. For now I guess I'll have to live with the idea that Line of sight doesn't work.

Nifl's avatar

Nifl

Member since 30 Aug, 2011

None one is following Nifl yet!

Trophy Case

  • 13-Year Club
  • Email Verified

Progress

14/44
How to earn trophies