samOtero / PTDGame

A 3D reimagining of the original Pokemon Tower Defense game made in Unity.
17 stars 2 forks source link

Fix issue with duplicate towers when dragging from tower button #2

Closed samOtero closed 2 years ago

samOtero commented 2 years ago

Problem: When dragging from tower ui button we can duplicate the tower multiple times in the map. This is cause because Tower button never gets the unit object after a tower is created.

Solution: Potentially store unit in the tower button after it is created or somewhere else globaly.