hi iceman i dont understand how this Qfunction works getting confused with stdmode and anti count i am trying to make exp pots but they just disappear as well does the stdmode have to be same as anti count in db same as in QFuncion ??
If you're making a pot that gives exp on clicking, look in the Item database for BasicPill and the others that follow it. They do exactly what you want.
You'll need to tweak the exp value of course.
This item action is hard coded so you don't need to use STDMODE 31 or the anicount.
644
| BasicPill
| 3
| 13
| 1
| | | | 22
| | 500
| | | | | | | | | | | | 500
| 50
| | | | | | 0.0000
| | | 50
| | | | | | | NULL
| NULL
| NULL
| 128
| NULL
| NULL
| 13
| | | NULL
| NULL
| NULL
| BasicPill
| NULL
|
~~
The anicount number relates to [@StdModeFunc(44)] so the anicount field for your item would show 44 in the database table.
Your own clickable items need to be set with STDMODE 31 and anicount unique for your particular item. Once clicked, they will disappear whether or not any active code exists. If you want to give the player an option to use or not, after clicking, you'll need to code it.
This code was the entry for my Christmas event map.
If the player chooses Wintermap, they get teleported and that's that.
If they click the CANCEL option, the item (1 Snowflake in this instance) is given back. Remember, it's not actually given back but a new one is created.
This isn't a totally foolproof system as closing the window by the top right option will not give the item back. That said, the player should read the text !
The < > at the beginning of the lines simply acts as a TAB to take the text off the edge.
Code:
[@StdModeFunc(114)]
#ACT
#SAY
< >\
< >Do you want to go to the winterland map ?\
< >There are two levels of map and level 40 is\
< >the dividing level.\
< >Go to <[EMAIL="Wintermap/@wintermap1>\"]Wintermap/@wintermap1>\[/EMAIL]
< ><[EMAIL="CANCEL/@canceljump2>\"]CANCEL/@canceljump2>\[/EMAIL]
[@canceljump2]
#ACT
GIVE Snowflake 1
BREAK
CLOSE
[@wintermap1]
#IF
CHECKLEVEL 40
#ACT
TIMERECALL 45
MAPMOVE WE01EVENT_01 235 264
#ELSEACT
TIMERECALL 45
MAPMOVE WE01EVENT_02 235 264
BREAK
CLOSE
Hope this helps.