View Single Post
  #1  
Old 01-09-2006, 01:11 AM
JkWhoSaysNi JkWhoSaysNi is offline
Ruler of the graalaxy
Join Date: Feb 2005
Location: Great Britain
Posts: 488
JkWhoSaysNi is on a distinguished road
Send a message via ICQ to JkWhoSaysNi
Strange player.shieldimg problem.

I am having an impossible time setting player.shieldimg.

I've figured out that the shield gets almost instantly reverted when I change it.

I made this basic NPC:

NPC Code:
//#CLIENTSIDE
if (created) {
// Initialize the attributes
showcharacter;
setcharprop #3,head0.png;
setcharprop #C0,orange;
setcharprop #C1,white;
setcharprop #C2,blue;
setcharprop #C3,red;
setcharprop #C4,black;
setcharprop #2,shield1.gif;
shieldpower = 1;
dir = 2;
}


if (playertouchsme) {
player.shieldimg = "shield2.png";
}



When i touch the NPC my shield will change to shield2.png for a split second before reverting to what it was before.

I tried deleting all weapon npc's from my account and there are no other npcs in the level.

Why does it do this?
headimg,swordimg etc all work fine, but shieldimg does not.

This also seems to be a problem on showani's using findimg(index).actor.shieldimg

Any ideas why this is happening or how to fix it?

Thanks.
Reply With Quote