Ambiera Forum

Discussions, Help and Support.

Ambiera Forum > CopperCube > Help with CopperCube
Vegetation Spawner? Help plz

onceforloops2
Registered User
Quote
2022-10-06 01:57:32

I want to set up a vegetation spawning system for imported static 3d terrains. Using ccbCloneSceneNode and setting up random positions and rotations for the vegation models. Does anyone have an action or a .ccb file they can help me with???


onceforloops2
Registered User
Quote
2022-10-06 03:08:54

I've tried to use the "sm node spawner" and "bsg spawn" but have had trouble getting the meshes to stay in the game once the root spawner is disabled, there has to be a way to remove them from their root all at once so that they can be in game at runtime and have collision enabled.


onceforloops3
Registered User
Quote
2022-10-08 22:28:44

??? This is onceforloops, onceforloops2, onceforloops3 all the same person, forgot my password:(


sven
Registered User
Quote
2022-10-11 12:10:48

At weekend if i have time i can make script for that if you havent found solution already.


onceforloops3
Registered User
Quote
2022-10-11 21:46:13

Yeah I might need your help...That would excellent, thx:)


onceforloops3
Registered User
Quote
2022-10-15 21:12:20

@sven, please help if you can...


sven
Registered User
Quote
2022-10-15 23:05:34

Here is script i made -example project included.

https://drive.google.com/file/d/...

I included .bmp file with INFO so make sure to read it if you dont understand the usage of script.

If script is not what you was talking about then let me know and i make new script or edit it if needed.
(this script is not fully tested because i made it very fast- so let me know if you have problems with it.)


onceforloops3
Registered User
Quote
2022-10-16 15:55:00

Thanks @sven, really cool you could that for me and others in the community. It feels good to bring request up on this forum, and have the code written by a good programmer like you so others can use it too. I think it is a very useful action:)


sven
Registered User
Quote
2022-10-16 16:33:57

wrote:
Thanks @sven, really cool you could that for me and others in the community. It feels good to bring request up on this forum, and have the code written by a good programmer like you so others can use it too. I think it is a very useful action:)


I am glad you find it useful.
NB i forgot to add random rotation..

just edit the script and replace this line..
ccbSetSceneNodeProperty(SRND_M[this.ID].node[i], "Rotation", 0, 90, 0);
with..
ccbSetSceneNodeProperty(SRND_M[this.ID].node[i], "Rotation", 0, rndrotationy, 0);

in file in your script folder..
Filename : action_SRND.js



i cant use code tag -dont know whats wrong with this forum.
[code]


Create reply:


Posted by: (you are not logged in)


Enter the missing letter in: "I?ternational" (you are not logged in)


Text:

 

  

Possible Codes


Feature Code
Link [url] www.example.com [/url]
Bold [b]bold text[/b]
Image [img]http://www.example.com/image.jpg[/img]
Quote [quote]quoted text[/quote]
Code [code]source code[/code]

Emoticons


   






Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact