DrawInfo help

Questions and answers about the how and why of making maps.
Post Reply
User avatar
Crallion
Private First Class
Private First Class
Posts: 201
Joined: Mon Mar 09, 2009 6:26 am
Location: The USA
Contact:

DrawInfo help

Post by Crallion » Mon Apr 13, 2009 9:22 am

No, I do not want somebody to tell me how do the basics of DI, I have a specific question about the trajectories of objects. So, can I use DI to make an object with a trajectory as seen in the attached file? I want an object to crash into the map over and over again about every minute. Is there a way to do that with DI?
Attachments
trajectory pic
trajectory pic
aname.png (10.09 KiB) Viewed 554 times
Time is a great teacher, but unfortunately, it kills all its pupils ... - Louis Hector Berlioz

To err is human. To really foul up requires the root password.

User avatar
Jefenry
Private First Class
Private First Class
Posts: 154
Joined: Thu Sep 14, 2006 3:56 pm
Location: TextEdit
Contact:

Re: DrawInfo help

Post by Jefenry » Mon Apr 13, 2009 6:10 pm

Yes. You can use a dynamicColor to make the object's textures go invisible. Then you'll need to sync the angvel of the drawInfo to the amount of time you specified your dynamicColor to turn invisible.
It'll be a bit of work, but definitely doable.

Your object won't fall in a perfectly straight line, but a large radius will make it less obvious.

User avatar
optic delusion
Special Forces
Special Forces
Posts: 990
Joined: Sat Sep 25, 2004 2:29 pm
Location: Planet MoFo
Contact:

Re: DrawInfo help

Post by optic delusion » Tue Apr 14, 2009 2:35 am

Here's what i think you want to do...
have an object come from above, in a straight line, and hit the ground. (and explode?)

There is no linear motion with angvel.. it will need to travel in a very large circle. Use an angvel of 6 for a one minute rotation. I think it would be best to build your obj at a Z of 0, then convert it to drawinfo, then place it in a define and use spin in the group to get your height.
It's gonna be underground at some point, which is ugly, Getting the dyncol to make it disappear at exactly the right moment will be difficult. LOD and extents/sphere will not work for this.
You will definitely have to experiment a lot to get it right.
Take a look at my Defender game mode concept.

Thinking is not an automatic process. A man can choose to think or to let his mind stagnate, or he can choose actively to turn against his intelligence, to evade his knowledge, to subvert his reason. If he refuses to think, he courts disaster: he cannot with impunity reject his means of perceiving reality.

User avatar
Crallion
Private First Class
Private First Class
Posts: 201
Joined: Mon Mar 09, 2009 6:26 am
Location: The USA
Contact:

Re: DrawInfo help

Post by Crallion » Tue Apr 14, 2009 2:39 pm

Ok, thanks for the help. I figured on having to do a lot of experimenting anyway, so I'd better get to work. :D
Time is a great teacher, but unfortunately, it kills all its pupils ... - Louis Hector Berlioz

To err is human. To really foul up requires the root password.

User avatar
JeffM
Staff Sergeant
Staff Sergeant
Posts: 5173
Joined: Fri Dec 13, 2002 4:11 am
Location: https://discord.gg/NN9uAvx
Contact:

Re: DrawInfo help

Post by JeffM » Tue Apr 14, 2009 10:46 pm

You should note that drawinfo is not a generic animation system, what you would be doing may not show up the same on all systems. It would also not be collide-able with anything (shots, tanks, etc..)

trepan
Dev Wizard
Dev Wizard
Posts: 704
Joined: Fri Feb 21, 2003 7:50 pm

Re: DrawInfo help

Post by trepan » Tue Apr 14, 2009 11:28 pm

DrawInfo's animation can only do circles, so it's definitely not a generic animation system.
The "may not show up the same on all systems" needs a better explanation. There are 2
types of BZDB variables that will affect the way that drawInfo's are rendered (besides the
standard texturing/lighting/etc... settings).

1. useDrawInfo
If set to "0", drawInfos will not be rendered. Its default state is "1", and there are probably
very few that even know that this option exists, so it's not a real concern.

2. lodScale and radarLodScale
Those two variables control the levels at which drawInfo LODs are used (Levels Of Detail).
If you aren't using LODs, then you need not concern yourself with them.

As for the drawInfo animation timing, it uses the GameTime timer (the same as used by
the TextureMatrix and DynamicColor material properties). It's the first instance of a smoothed,
synced, high resolution timer in BZFlag, and it should make the rendering appear the same on
all of the clients for any given time. If not, it needs to be fixed ;-)

Post Reply