Exemplo n.º 1
0
        public void setStationaryNPCImages(ContentHandler content)
        {
            for (int i = 0; i < npcList.Count; i++)
            {
                int direction = npcList[i].getFacingDirection();

                if (direction == 0)
                {
                    npcList[i].setNewAnimation(content.getNPCContentHandler().getNPCImages()[npcList[i].getName()]["STATIONARY_UP"]);
                }
                else if (direction == 1)
                {
                    npcList[i].setNewAnimation(content.getNPCContentHandler().getNPCImages()[npcList[i].getName()]["STATIONARY_DOWN"]);
                }
                else if (direction == 2)
                {
                    npcList[i].setNewAnimation(content.getNPCContentHandler().getNPCImages()[npcList[i].getName()]["STATIONARY_RIGHT"]);
                }
                else if (direction == 3)
                {
                    npcList[i].setNewAnimation(content.getNPCContentHandler().getNPCImages()[npcList[i].getName()]["STATIONARY_LEFT"]);
                }
            }
        }