I have created a small minigame for my 4th project of unity in my life (yes I am a newbie game dev so any help would benefit me greatly) and I’m currently stuck on increasing the gameObject size as a multiple.
This is the code I used:
void OnCollisionEnter(Collision collision) { if(collision.gameObject.tag == "RedSlime") { slimeSound.Play(); Destroy(collision.gameObject); transform.localScale = new Vector3(1.5f, 1.5f, 1.0f); } }
and at the transform.localScale instead of creating a new vector3 my goal is to multiply the current gameObject size by 1.1
Any help would be greatly appreciated and thank you for reading my question (and hopefully answering).