Default Attributes

How do I set Def. Attr2 ?
I tried setplayerprop #P2,myimage.gif; but it’s not working :frowning:

setplayerprop #P2,myimage.gif;

Does set the ATTR2 in ganis.
To change “Def. Attr2” (Default ATTR2) you edit the gani itself, this is meerly for when viewing the gani in “graalshop”.

ahh shit, so if I have a gani lets say with a sword, I have to make a new gani everytime I want a different sword O_o

Not exactly.
Add/Edit Sprite -> Image: ATTR2

Anytime you “setplayerprop #P2,somethinghere;”
ATTR2 will become “somethinghere” as the string. If the string happens to be an image or a gani, then the item in question will be drawn at the sprite location within the gani.

Developer Note:
We are limited to ATTR 1~5, the client’s theoretical range is 1~30.
The reason we do not have access to 6~30 is because the client does not notify the GServer about their changes, meaning they do not save or broadcast to other players.

k I understand how it works but setplayerprop #P2,myimage.gif; isn’t working -.-

like let’s say I made a walking gani with a sword, so the player walks with his sword out, so I set my attr2 to the sword image im using, and if I want to change the sword in the game I set setplayerprop #P2,myothersword.gif; and it should work,yes?

Should work yes.
However things can break it. Like not being case sensitive. “ATTR2” vs “attr2”
Or using an invalid image, (has a palette with more than 256 colors) or one that the client doesn’t know of.

bah damnit I checked everything :frowning: thanks anyways, really appreciate it

Try typing the image name into an NPC on a level. If it doesn’t show, theres something wrong with the image. Test ATTR with pics1.png as a test?

hmmm the image is invisible because you don’t have a sword immediately in the beginning but the editor isn’t saying ‘error: can’t find mysword0.gif’ when I hit test so it’s finding it ok.

I tried setting it to pics1.png but it still shows the sword I used to make the gani haha, idk its pretty weird

It doesn’t show “the sword you make the gani”, ever, in the graal client, unless that is currently set as your (#P2) ATTR2. Make sure your sword images in the gani use “ATTR2” as the image, then along the right hand side, put def attr2 myswordimg.gif

WOW! I totally fucked that up, I imported THAN set the attribute, I’m supposed to set it first than import as ATTR2, haha wow x_x