godot-ply 
Godot plugin for in-editor box modeling.
Only tested in Godot 3.3.3. Icons are only good for dark mode.
See demos on youtube.
Installation
- Copy the contents of this repository into your
addons
folder for your godot project. - Activate the plugin in your project settings.
Usage
Create a PlyInstance node in your scene, and select it.
Editing Meshes
There are four selection modes:
There are two editor modes are toggled by the
`
Transform toggle in the menu.
- Selection mode: select faces, edges, and vertices with the mouse
- Transform mode: use the gizmo to translate, rotate and scale
There are tools for each selection mode:
- Mesh
- Generators
- Plane: Generate a two-sided unit plane
- Cube: Generate a unit cube
- Generators
- Face
- Edge
- Vertex
- None, yet!
Collisions
Collision meshes are updated automatically if there is a CollisionShape child of the PlyInstance at $StaticBody/CollsionShape
. This is the default naming if you use the Create Trimesh Static Body
tool.
Details
Meshes are meant to only be oriented manifolds. Some properties:
- Each edge has one or two faces (although we generally use exactly 2)
- All of an edge's faces have compatible orientation -- that is the edge origin and destination are in opposite order for opposite faces.
Ply uses a winged edge representation for edges, but omit counterclockwise navigation:
omitted
left ccw right cw
\ /
\ /
\ /
o destination
^
|
left face | right face
|
o origin
/ \
/ \
/ \
left cw right ccw
omitted
Implications
Given this representation, a few limitations occur that are representable in other tools:
- One cannot abritrarily extrude edges into one-sided faces, or one edge would be incident with >2 faces.
- One cannot flip individual faces, as the faces would no longer have compatible orientation.
Contributing
Feel free to contribute! Both issues and pull requests are very welcome.
Feel free to contact me on the godot discord server, where my name is hints