nidh0gg's Recent Forum Activity

  • I have two identical events but each for a different type of object [Adventurer] and [enemyUnits] (latter is a family but I don' think this should be an issue). One is functioning exactly the way I want it to:

    When the object instance variable reaches 0 health

    -->Destroy all instances of dummyAttack that targets the object

    -->Destroy all instances of dummyAttack created by the object (that has no health)

    *-->Set the variable of "target" to 0 for all instances of the object Adventurer

    -->Destroy all objects related to the instance with 0 health

    So this works perfectly fine when the enemyUnits object reaches 0 health and almost perfectly for when the Adventurer object reaches 0 health except one specific trigger.

    The specific trigger that is not working properly is the part for setting the "target" variable to 0, I tested using debug and when splitting up the units like displayed below, Once the top Adventurer dies only ONE of the enemyUnits object has their target variable reset to 0 however the rest are unchanged.

    I tested the adventurer death trigger for when the object enemyUnits die by creating a mass of Adventurers and when one enemyUnits dies it properly resets all referenced Adventurer's target variable back to 0.

    Events for the Working death of enemyUnits objects

    Events for the Not-Working death of Adventurer objects

    .c3p Project File: dropbox.com/s/f6b1nsic787hpqu/triggerIssue.c3p

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads

    > what would the proper way to stop them from stacking/fusing on top of each other?

    Unfortunately, there is no proper way. There are many methods, but none of them work 100% correctly. You can search this forum for something like "pathfinding no overlapping". Also, I have two demos which are a bit complex, but may give you some ideas:

    https://howtoconstructdemos.com/avoid-overlapping-while-moving-with-pathfinding/

    Ill look into those demos, thanks again for all your help!

    > made the event and log but what am I suppose to enter for the message?

    Whatever you want. For example, Log "Adventurer "&Adventurer.UID&" FIND PATH"

    Then open browser console in preview and watch for this message.

    .

    The problem is Turret behavior, it somehow prevents Pathfinding from moving. I'm guessing it tries to change the angle.. If you disable Turret immediately after "Find path", then the adventurer moves correctly. Try using a different sprite for turret behavior, pinned to the Adventurer sprite.

    Also, using Solid on the same Adventurer sprite can cause problems, don't do this. Same with adding Adventurer sprite to obstacles.. If you want to prevent multiple adventurers from bumping into each other, this is not the right way to do it.

    Thanks that looks like it fixed it, I guess ill have to create a third sprite for each adventurer... but I guess theres not much i can really do about it. Also, you said that making each adventurer sprite a solid is not the right way to stop them from bumping into each other, what would the proper way to stop them from stacking/fusing on top of each other?

    Check your cell size, reduce it if necessary. Check the cell padding as well, I believe it defaults to -1, which could allow your object to move into a wall and have overlapping problems. If you're using move along path to move your object, try increasing your rotation speed from 100 to 1000 or even higher - this will let you get more direct movement between nodes, depending on the scale of your project and speeds involved.

    Yup, looks like the cell padding was set to -1, changing it seems to have fixed that overlapping issue. Thanks!

    Make sure that your "Find path" action is only triggered once, and not on every tick. You can add "Browser -> Log" debug message, then in preview press F12 and open browser console, you should see this message appear once.

    Maybe there is something else preventing the Adventurer from moving. Does it have any other movement behaviors, like MoveTo, Physics etc.? Check if pathfinding speed is set in behavior properties.

    If nothing helps, please share your project file, as I don't see any problems on your screenshots.

    I couldn't figure out how to setup the browser log debug (made the event and log but what am I suppose to enter for the message?) so I just set it so the find path only triggers every x seconds but that didn't seem to help.

    There is no other movement triggers on the Adventurer object other than pathfinder

    my project file is: dropbox.com/s/fylp04pa2mims8k/pathfinding_help.c3p

    thanks

    Sorry, it seems my debugging screenshot was cut off, heres the full pathfinding info

    puu.sh/Ffijf/80d313bf27.png

    (not sure why forum won't let me add anymore pictures?)

    Hi, I'm having some real troubles with the pathfinder behavior here. The path finding part seems to be working perfectly fine:

    The green square is a solid object and the red arrows (taken from tutorial to mark path) has properly created a path towards the target (based off turret behavior and nearest target).

    however when it actually starts moving (it also doesn't move immediately it takes it like 3 seconds even though the path has already been found) it completely ignores it and runs straight and then gets stuck inside the green square solid.

    Not to mention, depending on where you put the object with pathfinder it won't even move at all.

    (pathfinder object is just stuck there)

    (debug shows the path is found and object is moving BUT speed is 0, trying to change it does not work at all and trying to add a change speed (e.g 200) to the event for when path found --> follow path doesn't do anything at all)

    Here is the pathfinder code im using

    The catchall to make units move

    The function to determine what the path target is

    and lastly the function for setting up the objects with pathfinder (not sure if this one is relevant)

  • If these are top-level events, then "For each DummyAttack" is triggered on every tick, but you have another condition "Every DummyAttack.attackSpeed seconds".. Not only this is not good for performance, but I can't imagine how these two conditions work together, especially if different instances have different attackSpeed values.

    Use Timer behavior instead. When DummyAttack is spawned, start its Timer. In "On timer" event do "For each DummyAttack", pick Enemy, subtract from health.

    Thank you very much, this was exactly it.

  • I've just updated the site with some changes and tweaked our Azure settings which should improve performance after investigation. We've had sporadic outages for a little while now, and have been spending a lot of time trying to hunt down the cause and I do believe it's just about solved now.

    It is definitely a lot faster and more responsive now thanks!

  • Hi, I'm not sure why this is happening but I've been playing with the debug mode and whenever the "Adventurer" object triggers for overlapping it will properly spawn the "dummyAttack" object for each occurrence, however the for each trigger for "dummyAttack" does not properly subtract damage from the hp instance variable of the "Enemy" object. I've checked with debugging there is indeed multiple instances of the "dummyAttack" and the target UID's on them are also properly mapped but the trigger subtracts HP from 1 Enemy at a time.

    https://puu.sh/FdVaX/7b704c6f20.png[/img]

    I've been racking my brain over this and can't figure it out so if someone has some insight on this it would be greatly appreciated.

  • Is anyone else encountering this issue? Pages either take 5 minutes to load or they just never load at all, what's going on?

  • Is it possible to add live video feed from an IP camera or a google Nest camera?

nidh0gg's avatar

nidh0gg

Member since 16 Aug, 2019

None one is following nidh0gg yet!

Trophy Case

  • 5-Year Club
  • Email Verified

Progress

6/44
How to earn trophies