Grid
Grid(width, height, mode='line', thickness=1, **kwargs)
Located in ursina/models/procedural/grid.py
Overview
Generates a 2D grid of line segments:
width
,height
: number of cells along X and Zmode
:'line'
(grid lines) or'triangle'
(filled)
Fields
Name | Description |
---|---|
.width | Grid width in cells. |
.height | Grid height in cells. |
Example
from ursina import *
app = Ursina()
# 2×6 grid of lines
Entity(model=Grid(2, 6))
app.run()