This tutorial is set by the author's setting without permission.
This tutorial environment is tested in Kubejs 200.6.5-boild.14 and CustomPortalapi-0.0.1-Forge-20
const $ customPortalBuilder = java.loadClass ("net.Kyrptonaugt.customPortala.api.customPortalDer")const $ BuiltindiseNSionTypes = Java.loadClass ("Net.mineCraft.WORLD.Leveel.Dimension.BuiltindiseTypes"))))
Startupevents.postinit (e => {{
$ CustomPortalBuilder
.Beginportal () // Start construct a custom portable door
["FrameBlock (Net.MineCraft.WORLD.LEVEL.BLOCK.BLOCK)"] (Blocks.stone) // The frame of the portal of the portal
.Destdimid ($ BuiltindInSionTypes.nether_effects) // Transmission dimension
.Tintcolor (131, 66, 184) // The RGB color of the portal of the portal
.Registerportal (); // Register a custom portable door
$ CustomPortalBuilder
.Beginportal () // Start construct a custom portable door
["FrameBlock (Net.MineCraft.WORLD.LEVEL.BLOCK.BLOCK)"] (Blocks.diamond_block) // The framework of the portal .Destdimid ($ BuiltindIMENSIONSIONTYP. es.nether_effects) // Transmission dimension
.Lightwithitem (items.diamond) // Activate the items of the portal door
.Flatportal () //
.Tintcolor (131, 133, 184) // RGB color of the portal
.Registerportal (); // Register a custom portable door
})
Reference document: Custom transmittance | Kubejs1.20.1 tutorial