Flashlight: Difference between revisions
m
no edit summary
*>Monkey 05 06 m (→wikification) |
Monkey'05'06 (talk | contribs) mNo edit summary |
||
(5 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
{{ | {{thread|Flashlight module|30137.0}} by [[monkey_05_06]]. | ||
[http://www.meleepta.com/file.php?dir=ags&file=Flashlight_2_0_BETA_3. | Emulates the "flashlight" effect using a GUI or screen overlay. | ||
[http://www.meleepta.com/file.php?dir=ags&file=Flashlight_2_0_BETA_3.zip Download v2.0 BETA 3] | |||
[http://www.meleepta.com/file.php?dir=ags&file=Flashlight_1_9.rar Download v1.9] | [http://www.meleepta.com/file.php?dir=ags&file=Flashlight_1_9.rar Download v1.9] | ||
==Macros (#define-s)== | ==Macros (#define-s)== | ||
Line 31: | Line 30: | ||
''writeprotected DynamicSprite* Flashlight.BeamSprite'' | ''writeprotected DynamicSprite* Flashlight.BeamSprite'' | ||
Defines the DynamicSprite used as the 'beam' of the flashlight. This is essentially a black square with a transparent hole in the middle. You can use this property to delete the DynamicSprite before you quit the game and you can set the sprite using the Flashlight.SetBeamSprite method. | Defines the DynamicSprite used as the 'beam' of the flashlight. This is essentially a black square with a transparent hole in the middle. You can use this property to delete the DynamicSprite before you quit the game and you can set the sprite using the {{link||Flashlight.SetBeamSprite}} method. | ||
'''NOTE:''' This property does '''NOT''' support sprites with an alpha channel as the sprite is flattened while creating the sprite for the GUI/Overlay. | '''NOTE:''' This property does '''NOT''' support sprites with an alpha channel as the sprite is flattened while creating the sprite for the GUI/Overlay. | ||
Line 54: | Line 53: | ||
''writeprotected bool Flashlight.IsFollowingCharacter'' | ''writeprotected bool Flashlight.IsFollowingCharacter'' | ||
Returns whether the flashlight beam is following any character (this is the same as checking whether the {{link||Flashlight.FollowingCharacter|FollowingCharacter}} property is NULL). You can lock the flashlight's beam to a Character's position using the {{link||Flashlight.SetFollowCharacter}} method. | Returns whether the flashlight beam is following any character (this is the same as checking whether the {{link||Flashlight.FollowingCharacter|FollowingCharacter}} property is not NULL). You can lock the flashlight's beam to a Character's position using the {{link||Flashlight.SetFollowCharacter}} method. | ||
''See Also:'' {{link||Flashlight.FollowingCharacter}}, {{link||Flashlight.SetFollowCharacter}}, {{link||Flashlight.IsFollowingMouse}}, {{link||Flashlight.IsStatic}} | ''See Also:'' {{link||Flashlight.FollowingCharacter}}, {{link||Flashlight.SetFollowCharacter}}, {{link||Flashlight.IsFollowingMouse}}, {{link||Flashlight.IsStatic}} | ||
Line 196: | Line 195: | ||
b) call {{link||Flashlight.SetBeamSprite}} on a valid {{link|DynamicSprite functions and properties||DynamicSprite}} '''before''' turning the Flashlight effect on. | b) call {{link||Flashlight.SetBeamSprite}} on a valid {{link|DynamicSprite functions and properties||DynamicSprite}} '''before''' turning the Flashlight effect on. | ||
Failure to do this will prevent the module from working properly and prevent the {{link||Flashlight.Enabled}} property from being set (it will reset to '''false''' every loop until the {{link||Flashlight.BeamSprite|BeamSprite}} is properly set. | Failure to do this will prevent the module from working properly and prevent the {{link||Flashlight.Enabled}} property from being set (it will reset to '''false''' every loop until the {{link||Flashlight.BeamSprite|BeamSprite}} is properly set). | ||
==Licensing== | ==Licensing== |