• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Ideas on "night vision goggles"

Status
Not open for further replies.
Level 11
Joined
Nov 12, 2006
Messages
765
In my map the power can cut off, in which case the player can switch on his night vision goggles. I would like their to be a green tint on everything when this is switched on, anyone have ideas about getting a green tint on the screen?
 
Level 8
Joined
Nov 9, 2008
Messages
502
Ye there is that function to put a mask on the screen. Somewhere in cinematic or animation i think?

Whatever you do, make it better than Undead Assault please. That thing they have is almost unusable and pretty useless.
 
Level 8
Joined
Nov 9, 2008
Messages
502
Well you could try

JASS:
if GetLocalPlayer(player(0)) then
    DO that mask thing
endif

Although I just posted in another topic that using GetLocalPlayer can cause desyncs. Maybe that's if they are used too frequently, someone could clarify.
 
Level 12
Joined
Dec 10, 2008
Messages
850
Whatever you do, make it better than Undead Assault please. That thing they have is almost unusable and pretty useless.

NVG's in UA2 is a green tint on the screeen, so your just suggesting something that you said is "almost unusable"
Also, I'm pretty sure its mentioned in the text around a part were they become usesless, is that they do not work at the certain part.



Just be careful, becuase in UA2 (a map were this system is used) bugs when placed in a darker enviroment then what warcraft normally uses. So be carefull to the lighting of the darker part.
 
Level 8
Joined
Nov 9, 2008
Messages
502


NVG's in UA2 is a green tint on the screeen, so your just suggesting something that you said is "almost unusable"
Also, I'm pretty sure its mentioned in the text around a part were they become usesless, is that they do not work at the certain part.



Just be careful, becuase in UA2 (a map were this system is used) bugs when placed in a darker enviroment then what warcraft normally uses. So be carefull to the lighting of the darker part.

Yes when that dense fog comes. Maybe you can't use it with fog effects?
Part personal opinion. I guess night-vision is never comfortable, but I see no reason to use the nightvision in UA2. Slight attack boost for a headache? Up to you. If it had a better use, I would use it.


I'm limited to GUI, i should of mentioned that before. It isnt a big deal i suppose (if i cant get this to work).

That's ok just write it into a custom script
  • Actions
    • Custom script: if (GetLocalPlayer() == Player(0)) then
    • Cinematic - Apply a filter over 2.00 seconds using Normal blending on texture White Mask, starting with color (100.00%, 100.00%, 100.00%) and 100.00% transparency and ending with color (0.00%, 0.00%, 0.00%) and 0.00% transparency
    • Custom script: endif
Anything you put in the IF (the 2 custom scripts) will be for that player. Remember; Player(0) = Player 1, Player(1) = player 2 e.t.c.
 
Level 16
Joined
Jun 25, 2008
Messages
1,043
  • NightVison Is Casted
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Night Vision
    • Actions
      • Set TempPoint = (Position of (Triggering unit))
      • Set NightVisionPlayerNumber = (Player number of (Owner of (Triggering unit)))
      • Set NightVisionCaster[NightVisionPlayerNumber] = (Triggering unit)
      • Custom script: if (GetLocalPlayer()) == GetOwningPlayer(GetTriggerUnit()) then
      • Cinematic - Apply a filter over 10000.00 seconds using Normal blending on texture White Mask, starting with color (10.00%, 100.00%, 10.00%) and 70.00% transparency and ending with color (10.00%, 100.00%, 10.00%) and 70.00% transparency
      • Cinematic - Show filter
      • Unit - Create 1 ####A Dummy Unit#### for (Owner of (Triggering unit)) at TempPoint facing Default building facing degrees
      • Unit - Add a 20.00 second Generic expiration timer to (Last created unit)
      • Set NightVisionTimer[NightVisionPlayerNumber] = (Last created unit)
      • Unit - Remove Night Vision from NightVisionCaster[NightVisionPlayerNumber]
      • Unit - Add Turn Off Night Vision to NightVisionCaster[NightVisionPlayerNumber]
      • Custom script: call RemoveLocation(udg_TempPoint)
      • Custom script: endif
  • NightVision Ends
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to ####A Dummy Unit####
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Triggering unit) Equal to NightVisionTimer[(Player number of (Owner of (Triggering unit)))]
        • Then - Actions
          • Custom script: if (GetLocalPlayer()) == GetOwningPlayer(GetTriggerUnit()) then
          • Cinematic - Fade in over 1.00 seconds using texture White Mask and color (10.00%, 100.00%, 10.00%) with 70.00% transparency
          • Cinematic - Hide filter
          • Unit - Remove Turn Off Night Vision from NightVisionCaster[(Player number of (Owner of (Triggering unit)))]
          • Unit - Add Night Vision to NightVisionCaster[(Player number of (Owner of (Triggering unit)))]
          • Custom script: endif
        • Else - Actions
  • NightVision Turn Off
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Turn Off Night Vision
    • Actions
      • Unit - Kill NightVisionTimer[(Player number of (Owner of (Triggering unit)))]
This should work, (I tested it and everything seemed to work fine, but I don't know if the filter is actually only displayed to one player)
I also added so that when Nightvision is cast, the ability for that is removed and replaced with a ability to turn off the Night Vision :)
(yes, basically I just did the whole ability for you :D)
 
Level 10
Joined
Feb 22, 2008
Messages
619
Umm, you could make it so that when you turn on the goggles it creates a unit for the player with the goggles with a custom model that cannot be selected and the model is only a giant green see through thing and then give the unit a perminant invisability so that only the using player could see it and make it remove the unit when the goggles are turned off but to do that you would have to create a custom model, thats all I got.
 
Status
Not open for further replies.
Top