Bizarre idea: support resizing models in game
Moderator: Moderators
Bizarre idea: support resizing models in game
Imagine if, through some scripting command, we could set a particular unit to be constructed to be double in size.
I could set a factory to build half or double size units, or whatever percentage we want. This way we could store the same model, but have it represent essentially different things - a tiny version could have proportionately smaller damage, health, line of sight, and radar radius, for instance.
Or, maybe I just want to make giant peewees in my experimental gantry. Or a giant moho mine that covers 3 mexes.
If we want to get really fancy, we could even allow for dynamic resizing of an existing model rather than a newly constructed one. That way we could have a script to make the commander shrink really tiny or something.
I could set a factory to build half or double size units, or whatever percentage we want. This way we could store the same model, but have it represent essentially different things - a tiny version could have proportionately smaller damage, health, line of sight, and radar radius, for instance.
Or, maybe I just want to make giant peewees in my experimental gantry. Or a giant moho mine that covers 3 mexes.
If we want to get really fancy, we could even allow for dynamic resizing of an existing model rather than a newly constructed one. That way we could have a script to make the commander shrink really tiny or something.
- Guessmyname
- Posts: 3301
- Joined: 28 Apr 2005, 21:07
I suppose it is irrational intuition which leads some to believe that reducing the size of an object will reduce the strength it may exert as well as its structural integrity. Of course, this is bollocks - unless you remove mass as well, the increased density should lead to greater force exertion and durability.
Code: Select all
x = scale x axis multiplier
y = scale y axis by multiplier
z = scale z axis by multiplier
glPushMatrix();
glScalef(x,y,z);
// do unit rendering
glPopMatrix();- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Irrational intuition? Every single sci-fi/cartoon shrink ray I have seen has left density unchanged. Perfectly rational. Other than the shrinking process.neddiedrow wrote:I suppose it is irrational intuition which leads some to believe that reducing the size of an object will reduce the strength it may exert as well as its structural integrity. Of course, this is bollocks - unless you remove mass as well, the increased density should lead to greater force exertion and durability.
When you only render the model at half-scale, the legs, wheels, etc. will be moving at half the speed the model is.KDR_11k wrote:When you scale the model at rendering you don't have to rescale the move commands because it's internally handled at the old size, fools!
Hmm, if you're talking about the [ ] constant you set in Scriptor, it is used at compile time, not at run-time.Argh wrote:Use LUA to send a message to the COB that tells it to use a different constant for linear travel, voila, problem solved.
However you could, in your code, add a multiplication by a static-var in all the values of all your "move" command, and make that static-var changes when you shrink/enlarge.
Though, I'd go with what KDR said.
If you shrinked a krog to the side of a peewee an other krog could step on it and thus would have tactical advantage... :)neddiedrow wrote:I suppose it is irrational intuition which leads some to believe that reducing the size of an object will reduce the strength it may exert as well as its structural integrity. Of course, this is bollocks - unless you remove mass as well, the increased density should lead to greater force exertion and durability.
