Update main.cpp

fixed spelling of displacement,deleted displacement.x and .y, replaced them with horizontalDisplacement et al and added f after numbers so it would recognize them as floats