Hasuak's Forum Posts

  • Alright, double post, but I think I found a bug in the system. I recreated the player objects from my project into a blank project once again and this time the same problem arise. In my problem the player is built from a hitbox with platform controls, player's sprite on top of and pinned to that hitbox and then the gun set to the sprite's image point. This somehow causes the gun to lag. If I set it to the actual hitbox's image point there won't be any problems.

    I might be explaining things in a bit confusing way, so check the project out for yourself: https://dl.dropboxusercontent.com/u/505 ... tlock.capx

    Does this seem like an oversight from the devs? Or is there something I'm doing wrong? If someone feels like fixing this, keep in mind that setting the arm object to the blue object is vital. I can't set it to the red box and make it look good with the player's animations. That's just how my game is built.

  • have you tried it without the image point moving every frame? that might have something to do with it. you can pin it in the position of the image point, but not actually to the image point (I think), so it won't follow a changing image point. Really can't help much without seeing it firsthand.. Maybe open a separate project with the minimal pieces and see if you can pinpoint the problem and if not, share with us the new project capx and we'll do our best!

    I did remake the system on a blank file and the problem was solved. It must has to have something to do with the turret's constant changing of angle. The gun turns to face the direction you move into, so it's constantly rotating with a lerp effect. I've tried disabling as many conditions as possible but the problem just won't go away. I'll play around more today. Maybe there's something very obvious I'm just missing.

    Perhaps you're positioning the arm before the events that move the body. You should put your events that position the arm after the events that move the body. If the events that move the body are after the arm events, then it will look like it is lagging because the arm would be positioning itself to the previous body position and not the current position.

    I've tried putting the event to the very top and bottom of the event sheet but it's not changing.

    This is just so weird because the arm keeps lagging behind and looks like I've added some kind of lerping to it even if I haven't. Setting the object's position on every tic should logically make it work, but there's something more technical going on that's causing this.

  • Looks nice. Seems like you used Cave Story as reference for some graphics, am I correct?

  • The image point does move on every frame on running/jumping animations etc. The arm is not animated except when firing, but its own origin does not move. This should not cause lag like that. Framerate is a constant smooth 60 FPS. Can I pin objects to image points? I need to pin it to image points and not the origin point because otherwise the arm would look floaty and seperate from the character.

  • Had to start another thread since my turret arm system keeps giving me problems. I'm trying to create a system where the player's arm is seperate from rest of the body. I made an event where the arm sets its position to the body's image point 1 at every tick, but somehow the arm keeps lagging behind as if I added a lerp effect to it. I've checked many times that I hadn't done any lerping to its position, so I don't know why the arm keeps lagging.

    Basically all I'm doing is using a condition "every tick" and an event "Set position to Player_Sprite image point 1"

    I'm sorry if this is confusing. My project is rather large and full of holes currently so I can't really share it with you guys.

  • Oh, my. It's that simple. I've completely missed the anglelerp. Thanks for the help, this fixed my problem

  • I'm trying to create a turret arm for player that turns with lerp depending on buttons pressed. My problem is that I don't know how to change the lerp's direction from clockwise to counter-clockwise. The turret arm should rotate from pointing forward (0) to pointing straight up (270).

    The command I'm using is lerp(Player_Turretarm.Angle,270, 8*dt)

    I tried making the angle 270 to -90 but it just made the arm rotate nonstop like crazy.

  • In "System" events you can set the layout or layer angle manually. Try setting it to player object's angle maybe?

  • In my game I'm trying to make an enemy that throws a grenade or something similar into the air and I want it to hit the ground at the position where the player was at the moment of the throw. A simple mechanic some of you might know from Metal Slug and many other games. Is there a way to do this efficiently with physics objects or maybe somehow with the Bullet behavior? The grenade should ignore all collision except the floor, so hitting something accidentally shouldn't be a problem.

  • Hasuak I will try to tweak it later and figure it out

    Thanks, man. You're totally getting your name into my game's credits if you figure this out. Eh, you're getting there, do it or not

  • Well, I'm pretty stumped here. The current problem is that if I disable collision from an enemy, the other enemies can also walk through it. Then when the collision is enabled again, the other solid enemies can get stuck inside it. I'll see if someone is interested in solving this, but if nothing comes up I'll probably post this into somewhere where the devs might see into this. Somehow I think this wouldn't be such a hard thing to implement to this engine.

  • https://dl.dropboxusercontent.com/u/50541629/fixed.capx

    There you go! Should be fixed now.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hasuak

    fassFlash

    Try switching the collisions off for the enemy instead. I am not at a computer where I can update the CAPX. All the events that deal with the collisions for the player being turned off switch those with the enemy. That should work.

    That don't seem to work either. Also sorry, didn't notice your reply earlier. The problem is that the overlapping check doesn't work that way. The objects won't overlap at all during collision so the check becomes useless. I'm getting the feeling that this is something the devs have overlooked and is currently impossible to get working correctly.

    just an idea... I'm not even sure that 's a good idea

    Sorry, but I'm not using the Bullet behavior for enemy movement in my game so that won't work either, except only for special animations.

  • Hasuak

    looks pretty cool! Which plattforms do you aim for?

    Just PC and probably iOS at the moment. The art is pretty high resolution and even with the barebones of player and that monster's animations it's already about 15mb in scale, so it's way too big to be running on mobiles. Not that I mind since I've never been a fan of gaming on small screens

  • The characters have different resolutions and the colored ones seem to be rescaled which makes them blurry. Not a very professional thing to have in your game.