Posted: 27th Jun 2007 18:41
Is there a way to resize an object, (such as a simple cube, spher, etc...) wihout using Scale Object () ? I want to be able to resize an object by literals not percentages.
Posted: 27th Jun 2007 18:48
As far as I understood you could do it with scale object... maybe this way (didn't test the function):

+ Code Snippet
function SizeObject(Obj,X#,Y#,Z#)
   XS# = Object size x(Obj)
   YS# = Object size y(Obj)
   ZS# = Object size z(Obj)
   xf# = X#/XS#
   yf# = Y#/YS#
   zf# = Z#/ZS#
   scale object Obj, xf#,yf#,zf#
endfunction
Posted: 27th Jun 2007 19:12
Thank you, Sir. That is actually the alternative method I was considering if DBPro didn't have a built-in command.
Posted: 27th Jun 2007 19:13
Also, Sir, your method would work if you multiplied the percentages by 100. Since Scale Object only works with integers not floats.
Posted: 27th Jun 2007 20:24
Yes, right, sorry, I forgot that..
I don't think there is another way to do it.. (at least their is no command I know), and, btw, why do you call me 'Sir'? I'm scared..
Posted: 28th Jun 2007 13:34
maybe its stereotypical english talking... wait a minute isnt that guv'ner
Posted: 28th Jun 2007 14:35
Sir, is just a polite way to address people you don't know the forname of.

It's rarely used by the English any longer unless you go into a very posh shop or you are talking to you school teacher or applying for a job.

I would say Man ID Unknown has been taught better English lessons than most of us get in school

p.s. another way to make objects bigger without scaling is to make your world smaller. It might sound crazy, and you are wondering why you should ever do it, but by shrinking things below 16bit/65000 units can realy speed things up!
Posted: 28th Jun 2007 14:37
light is the key, nothing to do with respect.
Posted: 28th Jun 2007 20:10
If you really want to steer clear of the scale object command, you can use vertexdata to size your object. The only benefit I've found with this is that it doesn't mess with the lighting of the object, but here is how you would do it:

+ Code Snippet
obj = 1
scalex# = 1
scaley# = 1
scalez# = 1

   perform checklist for object limbs obj
   lnum = checklist quantity()-1
   for l = 1 to lnum
         lock vertexdata for limb obj,l
         num = get vertexdata vertex count()

         for n = 0 to num-1
            x# = get vertexdata position x(n)
            y# = get vertexdata position y(n)
            z# = get vertexdata position z(n)
            set vertexdata position n, x# * scalex#, y# * scaley#, z# * scalez#
         next n
         unlock vertexdata
   next l


You can mess with the values at the beginning of the code to change the size of the object and which object you are applying it to.