It's worth speaking a bit of French : doesn't need to be that good, because most Moroccans' French isn't that good either, but there are different prices for different foreigners
Cheapest -> most expensive
- Moroccan-resident foreigner, usually French or Belgian, etc
- French or Belgian
- British (which includes Australians, etc as we're all the same to a Moroccan), other European
- German, American, Japanese
They'll charge basically what they think you'll pay. Residents know the score so know what things really cost, Francophones will argue with them and so get a better price, Germans/Americans/Japanese just get charged the Earth.
I asked for 'un bouteille de l'eau' in a shop in a small town and was charged one price, one of our group came in a few seconds later and asked for 'a bottle of water' and was charged double...