I face this situation all the time while making a game, for example say if your game has ores and you want each ore to give the player a unique reward. What I do in such situation is make an IF statement for each ore in all the weapon scripts and that's inefficient and time consuming.
Say if I had a game with lots of enemies and each type of enemy would add a unique amount of number to the player's score when killed. How would I do that without nested if statements? And preferably without even doing anything to the weapon script if possible, like have the weapon just send a remote event to a server script that handles everything when the player kills an enemy.