From 4bb585169c5e832ffff88bcc06ab4392c4cfe669 Mon Sep 17 00:00:00 2001 From: Joe Shochet Date: Wed, 5 Dec 2001 01:32:07 +0000 Subject: [PATCH] *** empty log message *** --- direct/src/showbase/Transitions.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/direct/src/showbase/Transitions.py b/direct/src/showbase/Transitions.py index 2b1341148e..9ac54c0d4a 100644 --- a/direct/src/showbase/Transitions.py +++ b/direct/src/showbase/Transitions.py @@ -97,6 +97,17 @@ class Transitions: self.fade.reparentTo(aspect2d, FADE_SORT_INDEX) self.fade.setColor(0,0,0,alpha) + def fadeScreenColor(self, color): + """ + Put a semitransparent screen over the camera plane + to darken out the world. Useful for drawing attention to + a dialog box for instance + """ + self.noTransitions() + self.loadFade() + self.fade.reparentTo(aspect2d, FADE_SORT_INDEX) + self.fade.setColor(color) + def fadeOutTask(self, task, time=0.3, noFade=1): """ As a sequence: Fade out, execute the given task, then do a noFade