Help on Page Turning effect for Cocos Creator 3 and up

I’m trying to implement this to this Version(I also can’t post the Link)

or atleast an Updated version of this

I dunno what’s changed like:

  1. RenderData
  2. gfx and gfx.VertexFormat
  3. RenderComponent, Importing changed this to UIRenderable, but there no setVertDirty Function and getPointCount function.
  4. material.define()
  5. vector2.mag()

cc3_1
cc3_2
cc3_3
cc3_4
image

1 Like

Check this tutorial from our Chinese devs

Question5: vector2.mag() , you can use ’ a.length() ’ or ’ Vec2.len(a) ’ instead.

let p1 = new Vec2(100, 100);
console.log( p1.length);

let p2 = new Vec2(100, 100);
console.log( Vec2.len(p2) );