C# 클래스 OpenMinecraft.ProceduralTree

Set up the methods for a larger more complicated tree. This tree type has roots, a trunk, and branches all of varying width, and many foliage clusters. MUST BE SUBCLASSED. Specifically, foliage_shape must be set. Subclass 'prepare' and 'shapefunc' to make different shaped trees.
상속: Tree
파일 보기 프로젝트 열기: N3X15/MineEdit

공개 메소드들

메소드 설명
MakeFoliage ( IMapHandler &map ) : void
MakeTrunk ( IMapHandler &map ) : void
ProceduralTree ( long _x, long _y, long _z, int h ) : System
crossection ( IMapHandler &map, Vector3i vCenter, double radius, int diraxis, byte mat ) : void

Create a round section of type matidx in blocklist.

foliagecluster ( IMapHandler &map, Vector3i center ) : void

generate a round cluster of foliage at the location center. The shape of the cluster is defined by the list foliage_shape. This list must be set in a subclass of ProceduralTree.

makebranches ( IMapHandler &map ) : void

Generate branches.

makeroots ( IMapHandler &map, List rootbases ) : void
shapefunc ( int y ) : double

Take y and return a radius for the location of the foliage cluster. If no foliage cluster is to be created, return -1. Designed for subclassing. Only makes clusters close to the trunk.

taperedlimb ( IMapHandler &map, Vector3i vStart, Vector3i vEnd, int startsize, int endsize ) : void

Create a tapered cylinder in blocklist. start and end are the beginning and ending coordinates of form [x,y,z]. startsize and endsize are the beginning and ending radius. The material of the cylinder is 17, which indicates wood in Minecraft.

메소드 상세

MakeFoliage() 공개 메소드

public MakeFoliage ( IMapHandler &map ) : void
map IMapHandler
리턴 void

MakeTrunk() 공개 메소드

public MakeTrunk ( IMapHandler &map ) : void
map IMapHandler
리턴 void

ProceduralTree() 공개 메소드

public ProceduralTree ( long _x, long _y, long _z, int h ) : System
_x long
_y long
_z long
h int
리턴 System

crossection() 공개 메소드

Create a round section of type matidx in blocklist.
public crossection ( IMapHandler &map, Vector3i vCenter, double radius, int diraxis, byte mat ) : void
map IMapHandler
vCenter Vector3i the coordinates of the center block
radius double the radius of the section.
diraxis int The list index for the axis to make the section perpendicular to. 0 indicates the x axis, 1 the y, 2 the z. The section will extend along the other two axies.
mat byte What to make the section out of
리턴 void

foliagecluster() 공개 메소드

generate a round cluster of foliage at the location center. The shape of the cluster is defined by the list foliage_shape. This list must be set in a subclass of ProceduralTree.
public foliagecluster ( IMapHandler &map, Vector3i center ) : void
map IMapHandler
center Vector3i
리턴 void

makebranches() 공개 메소드

Generate branches.
public makebranches ( IMapHandler &map ) : void
map IMapHandler
리턴 void

makeroots() 공개 메소드

public makeroots ( IMapHandler &map, List rootbases ) : void
map IMapHandler
rootbases List
리턴 void

shapefunc() 공개 메소드

Take y and return a radius for the location of the foliage cluster. If no foliage cluster is to be created, return -1. Designed for subclassing. Only makes clusters close to the trunk.
public shapefunc ( int y ) : double
y int
리턴 double

taperedlimb() 공개 메소드

Create a tapered cylinder in blocklist. start and end are the beginning and ending coordinates of form [x,y,z]. startsize and endsize are the beginning and ending radius. The material of the cylinder is 17, which indicates wood in Minecraft.
public taperedlimb ( IMapHandler &map, Vector3i vStart, Vector3i vEnd, int startsize, int endsize ) : void
map IMapHandler
vStart Vector3i
vEnd Vector3i
startsize int
endsize int
리턴 void