If the tank crew shot first, the crew would not have been out of the tank on foot. But it is a rule of engagement that tanks do not fire in areas where civiliams (non-combatants) may be. Contrast this to terrorists who specifically target civilians.
German finance minister says need to limit number of refugees coming to Europe (Reuters)
from the article: IDF soldier killed by friendly fire on Gaza border