usbtypec's Recent Forum Activity

  • Are you using a Tilemap to create your layout? I once had a problem where I would "erase" tiles by painting with a fully empty tile, but this actually still puts the collisions there, you need to use the eraser tool instead.

    On the layout properties bar, at the bottom is a check box labeled "Show Collision Polygons". enable this and see if there is perhaps anything out of place / larger than normal.

    Hopefully this helps!

  • I don't ususally use Google Fonts so this may not be a big help, but here are some possible reasons / tips:

    1) check to see if the Text object has the Font property set to whatever font you want.

    2) It could perhaps be an issue with Google Fonts. I like to use FontStruct, you can make and download fonts and import as a .ttf file, and I've never had issues with it.

    3) This isn't likely, but it could be an issue with the editor or the device. Maybe the editor doesn't preview correctly?

    Maybe share a screenshot of more details to make it easier to find the problem.

  • Thanks yet again dop2000!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I don't know why this is happening, you might want to ask some users such as dop2000 or RojoHound about it, perhaps even Ashley if it is an engine bug.

    One idea is that perhaps your layout's assigned event sheet was changed? Check the layout's properties tab and check to make sure it is using the right event sheet.

    Other than that, I don't yet know what the cause could be. Sorry :(

  • So I want to create a sort of background effect that "bends" near the player. My first idea was to use the Bulge effect with a small radius and a negative scale, but then I found out I cannot set the position of the Bulge.

    Is there any way to do this or recreate the effect, maybe using meshes or something?

    Here is an example screenshot of what I want to achieve.

    Tagged:

  • Could you send a screenshot of your events? It's going to be much easier to help you if we can see what your events are.

  • On Right Mouse Click: System -> Create Object -> Fill out parameters

  • This will work as long as Set Angle is enabled for the bullet. If it isn't, use Set Angle of Motion instead.

  • Personally I like to use the physics behavior. It sounds crazy, but it works.

    -Make the enemy physics hitbox a circle

    -Set the enemy physics iterations to something like 2 or 3

    -Set world gravity to 0

    -To move them toward the player, use Set Velocity -> cos(angle(Enemy.X,Enemy.y,player.X,player.Y))*Self.speed for X and sin(angle(Self.X,Self.y,player.X,player.Y))*Self.speed for Y

    Hope this helps!

    EDIT: I am now just seeing you already tried Physics and it was laggy, sorry about that. Although you could try to reduce the physics iterations of enemies, this will make them update less and increase performance.

  • As for the health bar, create a Sprite and call it whatever you want (I'll be referencing it as HealthBar)

    (This method I am using will make a health bar that will shrink as the enemy loses health. There are ways to make it look better but this is the easiest)

    Make sure the origin point of HealthBar in the center.

    Add an instance variable to Enemy and HealthBar called "id". Add a global variable called idTracker.

    Make sure the enemies have an instance variable called "hp" and "maxHP". When an enemy spawns, set its hp and maxHP to whatever health it spawns with. When the enemy takes damage reduce hp but not maxHP.

    Then for events:

    Enemy -> On Created : System -> Spawn Object -> HealthBar (Position: Enemy.X, Enemy.Y-50), then another action -> Enemy -> Set instance variable "id" to idTracker. Then another action -> Add +1 to idTracker (This makes sure every enemy has a unique ID). Then another action -> HealthBar -> Pin to Object -> Enemy. Then another action -> HealthBar -> Set "id" to Enemy.id

    Then on a new event:

    If HealthBar.id = Enemy.id (this should work iirc) : HealthBar -> Set Width -> (Enemy.hp / Enemy.maxHP) * 100 (or replace 100 with whatever width the HealthBar is when full)

    ____________________

    Sorry if this is long or confusing. If you want me to recreate what I just typed above and send you the file, let me know.

    Edit: Fixed a typo

  • What do you mean by individualizing? The "if Enemy.X > Player.X" already check the X of every individual instance of X. There isn't any need to make a unique variable for every enemy. Here's the manual entry on Object Instances. (I think there was a manual entry on intance selecting but I couldn't find it)

  • I've been messing around with your file, and I'm somehow stumped. Something this simple shouldn't be hard.

    If I find a solution, I'll tell you, but for now I've got no idea.

usbtypec's avatar

usbtypec

Member since 25 Sep, 2022

Twitter
usbtypec has 2 followers

Trophy Case

  • 2-Year Club
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

8/44
How to earn trophies