Code:
[plevel 1]
guildonline
[function guildonline]
IF (<SRC.guild>)
src.ctag.gpage 1
src.dialogclose d_guildonline
src.dialog d_guildonline
else
src.sysmessage No guild !
endif
[dialog d_guildonline]
0,0
resize 0,0,250,520
dtext 15 15 044 Guild Online
dhtmlgump 15 490 200 25 0 0 <dsrc.ctag.gpage>.Page
if !(<dsrc.ctag0.gpage> == 1)
button 165 520 4014 4015 1 0 112
endif
local.az <guild.member.count>
local.a <eval <dsrc.ctag.gsayfa>*11>
if (<dlocal.az> > <dlocal.a>)
button 200 520 4005 4006 1 0 111
local.te 1
endif
local.awe <eval <dsrc.ctag.gpage> -1>
local.awe <eval <dlocal.awe>*11>
local.abc <eval <dlocal.az> - <dlocal.awe>>
local.satir 20
for <eval <qval (<dlocal.te> == 1)?11:<dlocal.abc>>>
local.aa <eval <dsrc.ctag0.gpage> -1>
local.aa <eval <dlocal.aa>*11>
local.aa +=<dlocal._for>
local.aa -= 1
obj=<guild.member.<dlocal.aa>.uid>
dhtmlgump 25 <eval <local.satir>+20> 200 25 95 0 <def.center><qval (<obj.isonline>)?<def.bfont_blue><obj.name>:<def.bfont_red><obj.name>>
button 10 <eval <local.satir>+25> 1209 1210 1 0 <dlocal._for>
local.satir +=30
endfor
[dialog d_guildonline button]
on 1 110
ref1 <src.guild.member.<eval <dargn>-1>.uid> /// following player
if (<src.uid> == <ref2>)
src.sysmessage You can not select yourself.
return 1
endif
if !(<ref1.isonline>)
src.sysmessage To follow people not connected to the game.
return 1
endif
if (<src.tag0.follower> == <ref1>)
src.sysmessage Are you following this person already.
return 1
endif
src.events +e_follower
src.tag0.follow <ref1>
src.sysmessage You following <ref1.name>. To cancel following .followquit !
serv.newitem i_follower,1,<src.uid>,1
on 111
src.dialogclose d_guildonline
src.ctag.gpage +=1
src.sdialog d_guildonline
on 112
src.dialogclose d_guildonline
src.ctag.gpage -=1
src.sdialog d_guildonline
[itemdef i_follower]
name Follow Guild Player
id 0186a
type t_eq_script
weight 0
layer layer_special
On=@Create
attr attr_decay|attr_newbie
timer 0
on=@equip
timer 0
On=@Timer
if !(<uid.<topobj.tag0.follower>.isonline>)
topobj.followquit
topobj.sysmessage You follow the player is not online.
remove
return 1
endif
if (<uid.<topobj.tag0.follower>.isdeath>)
topobj.followquit
remove
topobj.sys_kirmizi You follow the player is die.
return 1
endif
topobj.arrowquest <uid.<topobj.tag0.follower>.p.x>,<uid.<topobj.tag0.follower>.p.y>,<uid.<topobj.tag0.follower>.p.z>
timer 0
return 1
[function followquit]
if !(<findid.i_followeR>)
SYSMESSAGE You do not follow.
return 1
endif
SYSMESSAGE You closed the follow.
consume 9999 i_follower
arrowquest
tag0.folloWeR