Aydin -  27-07-2009 21:19
Kod:
[FUNCTION renamebag]
src.newitem i_memory_rename
new.trigger @dclick
return 1

[ITEMDEF i_memory_rename]
ID=i_memory
name=memory
type=t_script

ON=@DCLICK
target Select bag to rename.
return 1

ON=@TARGON_CHAR
SRC.MESSAGE You cannot rename that.
remove
RETURN 1

ON=@Targon_Item
if !(<SRC.TARG.BASEID>==i_bag)
SRC.MESSAGE That is not a bag.
remove
return 1
endif
IF ( <SRC.TARG.TOPOBJ.UID> != <SRC.UID> )
src.SYSMESSAGE <src.targ.name> must be in your pack.
remove
RETURN 1
ENDIF
src.dialog d_name_bag
remove
return 1

[DIALOG d_name_bag]
150,150
nomove
checkertrans 10 10 335 150
resizepic 190 175 5054 335 150
resizepic 200 185 3000 315 130
resizepic 220 235 3000 270 22
htmlgump 220 200 200 20 0 0 0
text 255 275 0000 1
button 220 275 4005 4006 1 0 1
text 435 275 0000 2
button 400 275 4017 4018 1 0 0
textentry 225 237 253 25 0 0 3

[DIALOG d_name_bag TEXT]
Enter new name for this bag.
Continue
Cancel
<src.targ.name>

[DIALOG d_name_bag BUTTON]
ON=0
ON=1
if !((strlen(<argtxt[0]>) > 30)
SRC.SYSMESSAGE Bag renamed to <ARGTXT[0]>.
SRC.TARG.NAME <ARGTXT[0]>
RETURN 1
else
src.sysmessage Name is loo long.
RETURN 1
endif

YORUMLAR (0)

Henüz yorum yapılmamış.

BENZER SAYFALAR

Yok