79832429

Date: 2025-11-28 09:52:12
Score: 1
Natty:
Report link

private void OntriggerEnter(Collider other) { ItemWorld itemWorld = other.GetComponent<ItemWorld>(); if(itemWorld != null) { // add to the player's inventory inventory.AddItem(itemWorld.GetItem()); // destroy from world itemWorld.DestroySelf(); } }

OntriggerEnter should be OnTriggerEnter

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: bunrot