Green and blue were out of order
Minor changes
changed conditions to match stcmp
using mine