add dyingChance property and fix some bug