Skip to content

Transition effect for Cocos Creator

Notifications You must be signed in to change notification settings

sardinec/transitions

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Transitions

This project is based on Cocos Creator 2.3.0.

Online Demo : https://2youyou2.com/transitions

image

Usage

image

  1. Add transitions node to the scene, the transitions node will make itself as a persist node.
  2. Select a transition in the Properties Panel.
  3. Use transitions.loadScene instead of cc.director.loadScene example:
// cc.director.loadScene(url, this.onLoadSceneFinish.bind(this));
this.transitions.loadScene(url, 'Canvas/Main Camera', 'Canvas/Main Camera', this.onLoadSceneFinish.bind(this));

Shaders

All shaders can be found in the folder: assets/resources/transitions/shaders

Builtin uniforms:

{
  texture: { value: white }
  texture2: { value: white }
  time: { value: 0 }
  ratio: { value: 1 }
}

Sources

About

Transition effect for Cocos Creator

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%