Scoobie101 Posted June 19, 2016 Share Posted June 19, 2016 I just have a really basic (probably) question/problem. How do I scale creatures in game? Like, use code to make them look smaller. I was doing what I do best and dug through already existing mods to try and find a scale related code and I found this in Hound Companions: inst.age = data.age local scale = easing.inQuad(math.random(), .5+(inst.age*.025), .025, 1) -- Base, Variance, ??? inst.Transform:SetScale(scale, scale, scale) Although, presuming inst.age refers to something my creature lacks (ageing) I don't think that would work... Link to comment Share on other sites More sharing options...
Aquaterion Posted June 19, 2016 Share Posted June 19, 2016 Well if you just want to scale them, and not make them scale over time like this you can just inst.Transform:SetScale(1, 1, 1) Link to comment Share on other sites More sharing options...
Scoobie101 Posted June 19, 2016 Author Share Posted June 19, 2016 Well that was easy, thanks :3 Link to comment Share on other sites More sharing options...
CarlZalph Posted June 20, 2016 Share Posted June 20, 2016 (edited) Do note that the Transform scale will also scale the movement speed for certain entities. You can also scale the entity with its animstate. inst.AnimState:SetScale(width, height) Also it takes two params for this one. Edited June 20, 2016 by CarlZalph Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now