synced up with Totte\'s changes
synced up with Totte\'s changes