Skip to content

Instantly share code, notes, and snippets.

void putToFloor(){
RaycastHit2D hit = Physics2D.Raycast(transform.position, -Vector3.up);
if (hit.collider != null)
{
transform.position = hit.point;
Debug.Log ("Putting here: "+transform.position);
}
Debug.Log ("Found nothing to hit: " + hit.point);
}
Sprite tempSprite;
SpriteRenderer changeSprite;
void Update(){
changeSprite = gameObject.GetComponent<SpriteRenderer>();
switch(type){
case 0:
{"lastUpload":"2021-03-02T02:37:26.635Z","extensionVersion":"v3.4.3"}