Gamestudio Links
Zorro Links
Newest Posts
Blobsculptor tools and objects download here
by NeoDumont. 03/28/24 03:01
Issue with Multi-Core WFO Training
by aliswee. 03/24/24 20:20
Why Zorro supports up to 72 cores?
by Edgar_Herrera. 03/23/24 21:41
Zorro Trader GPT
by TipmyPip. 03/06/24 09:27
VSCode instead of SED
by 3run. 03/01/24 19:06
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, Imhotep), 567 guests, and 4 spiders.
Key: Admin, Global Mod, Mod
Newest Members
sakolin, rajesh7827, juergen_wue, NITRO_FOREVER, jack0roses
19043 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