- This topic has 5 replies, 2 voices, and was last updated 1 year, 11 months ago by 
c4cc. 
- 
		AuthorPosts
 - 
		
			
				
2023-12-05 at 4:04 pm #68971
c4ccCustomerI need to decide whether or not an object is destroyed when it comes into contact with another.
I decided to reduce said object’s variable’s number (basically a health bar) if it comes into a certain close distance, using get distance puzzle as per below. Then if close enough, I want to hide the object.
Yet the object is not disappearing even though it is repeatedly in contact with another
FPS trialproduct 20.9.25 https://postimg.cc/gallery/LMM5vkQ/af43346e
2023-12-05 at 4:07 pm #68972kdv
Participantyou need to check the distance and set visibility every frame. now your puzzles are executed only once (when the app is loaded) and do nothing afterwards.
Puzzles and JS coding. Fast and expensive.
If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.
2023-12-05 at 4:25 pm #68974
c4ccCustomerSo far, it seemed to work, but I’ll run more tests and see how it goes
Attachments:
FPS trialproduct 20.9.25 https://postimg.cc/gallery/LMM5vkQ/af43346e
2023-12-05 at 4:52 pm #68976kdv
Participantit’s better use only one “every frame” puzzle for all your puzzles.
Puzzles and JS coding. Fast and expensive.
If you don’t see the meaning in something it primarily means that you just don’t see it but not the absence of the meaning at all.
2023-12-06 at 3:04 am #68986
c4ccCustomerit’s better use only one “every frame” puzzle for all your puzzles.
Thanks, I’ll keep this in mind. Do you mean, joining the puzzles together like this?
Also, in this updated puzzles, I’m trying to get my character to kick an enemy, thus destroying it. As you can see, I set my puzzles to hide the enemy object after the distance between puzzles determines the target is within kicking range, and when the HP is reduced to 0, or more.
But after a few kicks, only does the enemy disappear. Why is there a lag in disappearing?
FPS trialproduct 20.9.25 https://postimg.cc/gallery/LMM5vkQ/af43346e
2023-12-06 at 4:25 am #68987
c4ccCustomerAlso, in this updated puzzles, I’m trying to get my character to kick an enemy, thus destroying it. As you can see, I set my puzzles to hide the enemy object after the distance between puzzles determines the target is within kicking range, and when the HP is reduced to 0, or more.
But after a few kicks, only does the enemy disappear. Why is there a lag in disappearing?
On second thought, I may have solved this issue, by differentiating between left and right kicks. So now, my character sofar seems to be able to destroy by left or right kicks individually.
it’s better use only one “every frame” puzzle for all your puzzles.
So do you mean this for only my puzzles that determine damage and distance between objects?
FPS trialproduct 20.9.25 https://postimg.cc/gallery/LMM5vkQ/af43346e
 - 
		AuthorPosts
 
- You must be logged in to reply to this topic.
 




