Flashing night vision effect (Helmet Procedure)

Started by OrgeAlexj06 on

Topic category: Help with Minecraft modding (Java Edition)

Active 3 years ago
Joined Jul 2020
Points:
644

User statistics:

  • Modifications: 0
  • Forum topics: 4
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 4
Flashing night vision effect (Helmet Procedure)

Hello,
When I go in my custom armor, in the triggers for the helmet, I put a night vision effect for 20 seconds. When I test, the effect is at 1 seconds and flashes (between night vision and the end of the effect). Is there a solution? Thank you for your help

Good day !

Active 3 years ago
Joined Apr 2021
Points:
798

User statistics:

  • Modifications: 1
  • Forum topics: 14
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 292
Do "On the helmet tick…
Mon, 04/19/2021 - 18:47

Do "On the helmet tick update" try detecting if there's one second left. Then just clear the night vision effect by command.

If you have questions, please tell. I can give you some visual example on how to do it (with images)..

Good day!

Active 3 years ago
Joined Apr 2021
Points:
798

User statistics:

  • Modifications: 1
  • Forum topics: 14
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 292
I know its not in topic, but…
Mon, 04/19/2021 - 18:50

I know its not in topic, but I made a helmet wich blinks constantly:

--------------------------------------------

1. Create a variable called "Blink_Night"

1.1 Make the variable  (number type) and (player lifetime scope)

1.2 The result should look like this: https://ibb.co/B4WWf1q

--------------------------------------------

2. Just copy the code: https://ibb.co/ftkkjDs

-------------------------------------------

Active 3 years ago
Joined Jul 2020
Points:
644

User statistics:

  • Modifications: 0
  • Forum topics: 4
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 4
When i test the code (in…
Mon, 04/19/2021 - 19:36

When i test the code (in picture), it's flashing again... I'am on 1.12.2

Active 3 years ago
Joined Jul 2020
Points:
644

User statistics:

  • Modifications: 0
  • Forum topics: 4
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 4
I just want this : night…
Mon, 04/19/2021 - 19:38

I just want this : night vision stay at 20 sec but if I put 20 sec, the night vision flashing...

Active 3 years ago
Joined Apr 2021
Points:
798

User statistics:

  • Modifications: 1
  • Forum topics: 14
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 292
The code with you saw makes…
Tue, 04/20/2021 - 13:16

The code with you saw makes the helmet constantly blink..

and it won't work in 1.12, thanks to command changes.

Heres the tutorial for what you wanted : 

---------------------------------------

1. Create a variable called "Stop_Blink"

1.1 Make the variable (number type) and (player lifetime scope)

---------------------------------------

2. Heres the code: https://ibb.co/9s1sXKR

---------------------------------------

 

Active 3 years ago
Joined Apr 2021
Points:
798

User statistics:

  • Modifications: 1
  • Forum topics: 14
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 292
I don't understand, what do…
Tue, 04/20/2021 - 14:35

I don't understand, what do you mean "But 20 ticks? Cus ticks is a second" 60 ticks doesn't mean 60 seconds. Its the complete opposite. 1 tick happens every 0.05 seconds.

And if what you say is the case, why didn't the developers write seconds rather than ticks in the brick?

Active 10 months ago
Joined May 2020
Points:
734

User statistics:

  • Modifications: 3
  • Forum topics: 2
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 128
What are called "seconds" in…
Tue, 04/20/2021 - 17:17

What are called "seconds" in the procedures are in facts ticks (i don't know why, it's a bit weird). So in your procedure where you put 20 "seconds", it's ticks, so you put 20 ticks, which is only 1 second. Because of how the night vision effect works, the screen blinks in the last 5 seconds.

If you want your helmet to not make you blink, you have to put a least 101 ticks of night vision. 

Active 3 years ago
Joined Apr 2021
Points:
798

User statistics:

  • Modifications: 1
  • Forum topics: 14
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 292
Ok, if that's the case…
Wed, 04/21/2021 - 16:55

Ok, if that's the case.

Replace the numbers in my code

-------------

600 with 30

-------------

400 with 20

-------------

Done! Now it should work as intended.

Active 4 years ago
Joined May 2019
Points:
670

User statistics:

  • Modifications: 0
  • Forum topics: 1
  • Wiki pages: 0
  • MCreator plugins: 0
  • Comments: 1
Hello, I know I'm getting…
Sat, 05/29/2021 - 07:13

Hello, I know I'm getting involved in the discussion, but I have answered your problem, do the 20 seconds thinking that it's seconds, they are ticks, and 20 ticks = 1 seconds, so for me for a minute I put 1200 ticks in the procedure!
Knowing that 1 seconds = 20 ticks, you can find the number of ticks for the number of seconds you want! Here I hope to have you help!
Have a good day
Le_gameeer