Modifying Terrain height for editor?

Blitz3D Forums/Blitz3D Beginners Area/Modifying Terrain height for editor?

Orig_Loki(Posted 2003) [#1]
Hi all,
I have an editor I am creating to learn 3d programming, and everything is fine, but I can't seem to get the Terrain to go any higher then just 1 point. Can anyone help me out? :)

Here's my section of code that modifies the terrains height,
it's very basic! :(

Ta.

If(KeyDown(57)) Then
	ModifyTerrain Terrain,EntityX(EdCursor),EntityZ(EdCursor),1,True
EndIf


See very hardcore! - I can't seem to get it to keep raising the terrain, no matter what I put in place of the '1'.

TIA.


Floyd(Posted 2003) [#2]
Terrain height is always in the range 0.0 to 1.0, although you can
change the way it appears in the 3D world with ScaleEntity.


Orig_Loki(Posted 2003) [#3]
ahhh cool, thnx


Orig_Loki(Posted 2003) [#4]
Erm, stuck again. Whenever I load the app and try to edit, it does nothing. Then when I load a previously saved heightmap.bmp and edit the terrain, it raises all of the previously edited sections??

Is there any code that someone could supply to edit ONLY at a desired cursor point (*hint hint*) ;) - I'm new to this 3d-lark and it's rapidly getting on my t*ts. :)


Floyd(Posted 2003) [#5]
In the Castle sample that comes with Blitz3D you can shoot at the terrain and dig a hole.

It uses ModifyTerrain at the point where the bullet hits.