OFPEC Forum

Addons & Mods Depot => OFP - Addons & Mods Beta Testing => Topic started by: Homefry31464 on 22 Jan 2004, 19:01:50

Title: Tree's
Post by: Homefry31464 on 22 Jan 2004, 19:01:50
Hmm, I was thinking about all the new stuff thats been coming out, islands, etc.  What about tree's that sway.  I have a possible way for this to work, so bear with me.  

First, you need a tree model.  Then a custom animation that shows the tree moving back and forth.  


Now, I need to know a few things.  Can objects, such as tree's, have animations.  Secondly, can a script detect the player's location and locate all the tree's within a certain radius. Then could another script make those objects run the animation and make it sway in the breeze?

Thanks.
Title: Re:Tree's
Post by: asmodeus on 23 Jan 2004, 20:57:57
With my available knowledge and without testing it...

I say all of this is possible.  Now, whether or not it would create a huge amount of lag is another story.   :P   ;)

Asmo
Title: Re:Tree's
Post by: dmakatra on 23 Jan 2004, 21:07:17
I think it would look weird when I imagine the result ahead of me.

:beat: *Gets Shot* :beat:
Title: Re:Tree's
Post by: Kaliyuga on 23 Jan 2004, 21:10:12
 I'm not too sure how it would look either.. but it's definately possible..

and as far as lag goes.. the script can detect benchmark and allow x numer of tree pers depending on benchmark

:toocool:
Title: Re:Tree's
Post by: Homefry31464 on 23 Jan 2004, 22:22:37
Well, thats why you guys are here.  ;D  Is there a way to detect certain types of objects around the player within a certain radius, then just those tree's could sway, so there wouldn't be that much lag.
Title: Re:Tree's
Post by: Kaliyuga on 23 Jan 2004, 23:31:08
sure... something like:


condition:

 player distance array < x

activation:
[]  exec "sway.sqs"


the array would have to be all the possible trees and the sway.sqs would change the animation phase around over time...


Title: Re:Tree's
Post by: Homefry31464 on 23 Jan 2004, 23:46:13
So how hard would this be to actually do??
Title: Re:Tree's
Post by: Kaliyuga on 24 Jan 2004, 00:14:14
 I think it would be pretty easy to do actually....  

 I even have a palm tree model on my HD that someone wanted me to binarize a while back... I think it was Scud that made it .. I probably have his email around somewhere

Title: Re:Tree's
Post by: Dubieman on 24 Jan 2004, 00:22:24
Maybe you can use this script tree thing to alert you to an enemy's presecnce.
Like if they are walking through some trees or hiding in a big bush, it wiggles or sways. Kinda like when walking through a cornfield, the plants bend and sway.
Easier to see snipers too!  :gunman: