Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
Try this:
You might also want to brush up on Layers vs Masks. The "layer" is where the object lives, the "mask" is what it can see. Make sure the RayCast's mask includes the layer the terrain is on.
And yeah, I set the Raycast layer mask to look for layer 1, which is the same layer of the terrain I'm generating. But still doesn't work.
If you turn on "visible collision shapes" in the debug menu, you should be able to see the direction and length of the ray when you run the game. Very useful for debugging strange behaviour like this!
And seems like the ray is here, and shows that it's colliding in-game, but not code wise?
https://imgur.com/a/mdFiDfF
I tried making the world generation process be handled by _process() method, and have a delay of at least 1 before going from the step of generating chunks to the step of spawning the player character in the world, and it still doesn't work.
I changed the delay to 5 seconds, and still doesn't work..
I remembered that my project has a dictionary of vertices that are used by the game, so I used it to get the ground position.
I will only be able to get the position of the ground, but at least it works, and will be handy for placing objects on the map.
Thanks for at least trying to help with this, by the way.
Edit: Many sunflowers, by the way.
https://imgur.com/a/bLL4AhA