Khral : gefgef 201235010510510510051 tane konu açacacagına 1 konu aç yaşadıgın sorunları yaz arkadaşlar cevap verir 15015601601061060 konuya gerek yok yani kolay gelsin
[PLEVEL 1]
aim
[function is_hp_covered]
// argn = hitzone
doswitch <argn>
return 0
return <qval <link.findlayer.layer_helm> ? 1 : 0 >
return <qval <link.findlayer.layer_collar> ? 1 : 0 >
return <qval (<link.findlayer.layer_shirt> | <link.findlayer.layer_chest> | <link.findlayer.layer_tunic> | <link.findlayer.layer_robe> | <link.findlayer.layer_cape>) ? 1 : 0 >
return <qval (<link.findlayer.layer_shirt> | <link.findlayer.layer_chest> | <link.findlayer.layer_tunic> | <link.findlayer.layer_robe>) ? 1 : 0 >
return <qval (<link.findlayer.layer_arms> | <link.findlayer.layer_robe> | <link.findlayer.layer_cape>) ? 1 : 0 >
return <qval <link.findlayer.layer_gloves> ? 1 : 0 >
return <qval (<link.findlayer.LAYER_PANTS> | <link.findlayer.LAYER_SKIRT> | <link.findlayer.LAYER_HALF_APRON> | <link.findlayer.LAYER_ROBE> | <link.findlayer.LAYER_LEGS>) ? 1 : 0 >
return <qval (<link.findlayer.layer_shoes> | <link.findlayer.layer_legs>) ? 1 : 0 >
enddo
return 0
[function aim]
if <src.findid.i_aiming_mem>
return 0
else
serv.newitem i_aiming_mem
src.equip <new.uid>
endif
[itemdef i_aiming_mem]
id=i_arrow
type=t_eq_script
name="aiming memory"
on=@equip
timer=10
src.tag.HITPREFERENCE=
target "aim at whom?"
on=@targon_char
if (<src.targ.can> & mt_nonhum)
src.sysmessage="there's nothing you could aim at"
remove
return 1
else
timer=10
link=<src.targ.uid>
dialog d_hitzone
endif
on=@targon_ground
src.sysmessage="there's nothing you could aim at"
remove
return 1
on=@targon_item
src.sysmessage="there's nothing you could aim at"
remove
return 1
on=@targon_cancel
remove
return 1
on=@timer
cont.tag.HITPREFERENCE=
remove
return 1
[DIALOG d_hitzone]
0,0
page 0
resizepic 0 0 2620 398 299
gumppic 105 0 12 // body
gumppic 213 59 <qval <is_hp_covered 1 > ? 40 : 41 >
gumppic 74 70 <qval <is_hp_covered 2 > ? 40 : 41 >
gumppic 44 109 <qval <is_hp_covered 6 > ? 40 : 41 >
gumppic 227 95 <qval <is_hp_covered 5 > ? 40 : 41 >
gumppic 198 119 <qval <is_hp_covered 4 > ? 40 : 41 >
gumppic 73 155 <qval <is_hp_covered 7 > ? 40 : 41 >
gumppic 217 207 <qval <is_hp_covered 8 > ? 40 : 41 >
Group 0
radio 314 53 208 209 0 1 // Head
radio 48 63 208 209 0 2 // Throat
radio 18 200 208 209 0 3 // Back
radio 301 113 208 209 0 4 // Chest
radio 330 88 208 209 0 5 // Arms
radio 19 102 208 209 0 6 // Hands
radio 48 148 208 209 0 7 // Legs
radio 318 200 208 209 0 8 // Feet
button 80 245 238 239 1 0 100 // Apply
button 231 246 241 242 1 0 0 // Cancel
dtext 111 18 50 Select Preferred Hit Area
dtext 43 200 <qval <is_hp_covered 3 > ? 37 : 5 > Back
[DIALOG d_hitzone button]
ON=0 // Cancel
src.tag.HITPREFERENCE=
ON=100
for n 1 8
if <eval <argchk[<dlocal.n>]>>
src.tag.HITPREFERENCE=<dlocal.n>
endif
endfor
[eof]
21-05-2008, Nazghul
- Added: Combat flags to Sphere.ini to allow stacking armor and aimed hits. Example of usage
is in scripts/AddOns.
Aimed hits are controlled by tags on the "hitter": TAG.HITPREFERENCE holds the targetted
zone: 1=head, 2=neck/throat, 3=back, 4=chest, 5=arms, 6=hands, 7=legs, 8=feet (if the value
is out of this range it will be changed by %9; "0" means: no preference set);
TAG.HITPREFERENCE_CHANCE (0..1000) is the chance to really hit the desired area;
TAG.HITPREFERENCE.BONUS is the percent the damage is raised when hit where desired,
TAG.HITPREFERENCE.PENALTY is the percent the damage is lowered if the area was missed.
The last two values are defaulting to "30".
The system is perhaps useful to script a system where a player can look for weak armored
bodyparts of his opponent and try to hit him there; could be essential if armor stacking
is used.
CombatFlags=01000|02000
Bu iki flagın aktif olması şart.[Events e_deneme]
On=@Hit
TAG.HITPREFERENCE_CHANCE=1000 //Bu kısım %100 belirlediğiniz bölgeye vurmanızı sağlar.
TAG.HITPREFERENCE=<r1,8> //1 ile 8 arasında bir yere vur.
[Defname spmsg]
spmsg_01=Ah kafam
spmsg_02=Ah boynum
spmsg_03=Ah sırtım
spmsg_04=Ah göğsüm
spmsg_05=Ah kolum
spmsg_06=Ah elim
spmsg_07=Ah bacağım
spmsg_08=Ah ayağım
[Events e_deneme]
On=@Hit
TAG.HITPREFERENCE_CHANCE=1000 //Bu kısım %100 belirlediğiniz bölgeye vurmanızı sağlar.
TAG.HITPREFERENCE=<r1,8> //1 ile 8 arasında bir yere vur.
IF (<dTAG.HITPREFERENCE> == 1)
src.sersemle //Atıyorum bunu
ELIF (STRMATCH("<TAG.HITPREFERENCE>", "02"))
src.nefessizkal
ENDIF
src.sayu <def.spmsg_<TAG.HITPREFERENCE>> //Yani atıyorum ki <r1,8>, 1 olarak döndüyse. src.sayu Ah kafam