There is a general rule in land based casinos that a gambler shouldn't take credits left on a slot machine by someone else. Basically, from what I understand, if there is still credit showing on a slot machine. Don't cash out or add to your money you put into the machine. Right? The question is if you find a cash out voucher resting on the machine itself or on the seat, can you legally use it?
If you find a quarter or more then there is no harm in using it and that is what people do practically as far as I have seen so don't worry about the legal issues unless you find money that is a considerable amount like at least a hundred dollar which no one is going to leave it behind or they are too rich to consider 100 as a tip for someone.