16.12.2014, 23:36
A couple of things you could do to improve this.
1.) No need for OnFilterScriptExit() the streamer auto deletes anything created.
2.) You are using dynamic areas why bother looping through and doing IsPlayerInRangeOfPoint() checks makes no sense to me when all you need to do is record the current index then check if the player is in that area when doing a key press.
3.) TrashcanNotification[playerid][3] = CreatePlayerTextDraw(playerid, 383.333343, 344.711120, "Press ~r~ALT ~w~to interact~n~with a trashcan."); Use the correct ~k~ code instead of ALT it might be different depending on the players keys.
1.) No need for OnFilterScriptExit() the streamer auto deletes anything created.
2.) You are using dynamic areas why bother looping through and doing IsPlayerInRangeOfPoint() checks makes no sense to me when all you need to do is record the current index then check if the player is in that area when doing a key press.
3.) TrashcanNotification[playerid][3] = CreatePlayerTextDraw(playerid, 383.333343, 344.711120, "Press ~r~ALT ~w~to interact~n~with a trashcan."); Use the correct ~k~ code instead of ALT it might be different depending on the players keys.