component : fadein
Godot - game development for homies » Devlog
version 3.5.2 topic : component UI - Fadein
Let’s make a nice scene component that makes the whole screen transit from black to blank in 1.0 second.
- add scene node2D
- add ColorRect and rename it to “Fadein”
- under last add AnimationPlayer
Nice, that is all you need to have. Now resize the ColorRect to whole screen you will use for example 1024x600px.
Open the AnimationPlayer.
- add animation and name it “start”
- select the ColorRect “Fadein”
- add track for “color” and another track for “visible”
- now you need to set at 0.0 second frame time visible to “true” and color to “black”
- and for last 1.0 second frame set visible to “false” and color to “blank” that means alpha is at 0
- press the “autoplay” button so the things starts everytime a scene opens with this component
After this select the “Fadein” and save it as new branch into a “components” folder you make from which you will put it to the scenes at the end of each scene to block input until the scene shows.
As last step look if the default color of the ColorRect is blank. Because otherwise it would block your view at the scene.
Godot - game development for homies
Status | Released |
Author | Bastian |
Genre | Educational |
Tags | Godot |
More posts
- loading resources with gdscript4 days ago
- i was wrong!7 days ago
- physics collision and layers7 days ago
- tool ghosts8 days ago
- storing player position8 days ago
- component campfire8 days ago
- how to control things in a scene component9 days ago
- camera 2D9 days ago
- blocking my view eh?10 days ago