Gamestudio Links
Zorro Links
Newest Posts
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
Trading Journey
by howardR. 04/28/24 09:55
Zorro Trader GPT
by TipmyPip. 04/27/24 13:50
Data from CSV not parsed correctly
by jcl. 04/26/24 11:18
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (AndrewAMD, Quad, 7th_zorro), 923 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Displacing chunked terrain never works right #463921
01/06/17 18:39
01/06/17 18:39
Joined: Oct 2003
Posts: 4,131
M
Matt_Aufderheide Offline OP
Expert
Matt_Aufderheide  Offline OP
Expert
M

Joined: Oct 2003
Posts: 4,131
I trying to displace terrain by using ent_setvertex....
using the simple example from the manual:

int i = ent_status(terrain_ent,0);
for (; i>0; i--)
{ CONTACT* c = ent_getvertex(terrain_ent,NULL,i);
c.v.y += 100.0;
ent_setvertex(terrain_ent,c,i);
}

mostly works but always the edges of each chunk are not changed properly. I have set up terrain like this:

terrain_chunk=32;
ent_createterrain(NULL, vector(0,0,0),64,64,2048);

everything looks right to me... so why is this happening?

Last edited by Matt_Aufderheide; 01/06/17 18:39.
Re: Displacing chunked terrain never works right [Re: Matt_Aufderheide] #463925
01/07/17 15:34
01/07/17 15:34
Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
txesmi Offline
Serious User
txesmi  Offline
Serious User

Joined: Jun 2007
Posts: 1,337
Hiporope and its pain
Did you try passing 1 as entity status mode?

Re: Displacing chunked terrain never works right [Re: Matt_Aufderheide] #463945
01/08/17 22:43
01/08/17 22:43
Joined: Oct 2003
Posts: 4,131
M
Matt_Aufderheide Offline OP
Expert
Matt_Aufderheide  Offline OP
Expert
M

Joined: Oct 2003
Posts: 4,131
Thanks, that doesn't solve it... but I found the problem...it turns out that if you assign a material that has a tangent flag, it messes up your displacement...odd..all works fine when I turn off the tangent flag.. fortunately I don't need it.


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1