generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: CanCollide Resizing Problem

Previous Thread :: Next Thread 
klamman is not online. klamman
Joined: 06 Feb 2010
Total Posts: 436
26 Dec 2015 02:51 AM
I know that the position of a part (and rotation, but I need to learn how to use that, still) is changeable by manipualting the CFrame property of bricks, which will ignore CanCollide. Is there a similar way to do this with size?

Report Abuse
HarrySnotte is not online. HarrySnotte
Joined: 27 Jun 2011
Total Posts: 2854
26 Dec 2015 06:04 AM
you would have to save the cframe to a variable, change the size and then apply that cframe again, like this:

local cf = part.CFrame
part.Size = Vector3.new(10, 10, 10)
part.CFrame = cf
Report Abuse
klamman is not online. klamman
Joined: 06 Feb 2010
Total Posts: 436
26 Dec 2015 06:52 PM
Alright, thanks, that makes sense. Reestablishing the CFrame every time the size increases so that the brick itself doesn't move, correct? Now my problem is this:
Since the brick ignores CanCollide, its size increases on both sides - increasing both upwards and downwards, and therefore through the baseplate. Is there any way to prevent this, and make the brick's size only increase upwards?
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
26 Dec 2015 07:24 PM
part.CFrame = oldcframe + Vector3.new(0,ysizeincrease/2,0)
Report Abuse
klamman is not online. klamman
Joined: 06 Feb 2010
Total Posts: 436
26 Dec 2015 07:46 PM
Thanks Vlek, works perfectly. It shifts the position, I don't suppose there's a way to achieve the desired effect without changing the position? If not, can someone explain why this works? Thanks in advance, and sorry for all of the questions, haha.
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
26 Dec 2015 07:52 PM
Nope, as a part's size changes it's position has to change too unless you want it to increase on all sides, which isn't what you want.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image