首页 > 代码库 > unity3d 启用某层设置

unity3d 启用某层设置

1 << LayerMask.NameToLayer("Ground") 

只用某层

grounded = Physics2D.Linecast(transform.position, groundCheck.position, 1 << LayerMask.NameToLayer("Ground")); 

 

unity3d 启用某层设置