SphereCommunity
new skill riding - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Help (/Forum-Script-Help)
+--- Thread: new skill riding (/Thread-new-skill-riding)



new skill riding - aptillah - 02-20-2014 05:53 PM

hello again .. i try to make new skill riding but i cant.. i hope some person help me or send me abouth this script

example:

0-50 skill only horse
50-60 lama
60-70 forest
70-80 frenzied ostard
80-90 mustang
90-100 nightmare -unicorn

if my skills 45.0 when i ride horse
a certain chance horse drop me.. this is possible ?

skill gain on the horse only.. how i do like this ?


RE: new skill riding - JohnVeritas - 02-20-2014 07:16 PM

Check here for make your own skill

You can set riding skill properties under your custom player event with trigger on @mount. With this trigger you can drop player while riding like;

Code:
on=@mount // when player try to mount a ride.
if (<argo.id> == c_horse_tan)
   if (<src.riding_skill> < 500)
      if (<r4> == 1)
      src.dismount
      src.sysmessage At sizi uzerinden atti.
      endif
  endif
endif

If you want to dismount player time by time you can do it with an external item with timer. @timer item check cont.riding_skill and cont.findlayer.25.more1 if more1 is c_llama and <cont.riding> < 600 with a rand cont.dismount that all GRTS


RE: new skill riding - aptillah - 02-20-2014 09:00 PM

[SKILL 54]
DEFNAME=SKILL_RIDING
KEY=Riding
TITLE=Rider
STAT_STR=20
STAT_INT=70
STAT_DEX=30
BONUS_STR=0
BONUS_DEX=0
BONUS_INT=100
BONUS_STATS=50
ADV_RATE=2.5,50.0,200.0

ON=@Success
RETURN 2

ON=@Fail
RETURN 1

i tried to make new skill but i dont see skill name in game but i teach this sckill so problem is skill name in game..

i have 2 question
how i start to skill working when character walking on horse?
how i make dismount charachter %chance abouht riding skill?


RE: new skill riding - JohnVeritas - 02-21-2014 10:42 PM

Well you can simply add animals to def with rid_xxx (skill_riding) system works fine for me...

Code:
[DEFNAME RIDING_SYSTEM]
rid_c_llama    500

[SKILL 58]
DEFNAME=SKILL_Raiding
FLAGS=SKF_SCRIPTED
KEY=Riding
TITLE=Raider
PROMPT_MSG=
DELAY=1.0
ADV_RATE=2.5,50.0,200.0
STAT_STR=0
STAT_INT=85
STAT_DEX=0
BONUS_STR=0
BONUS_DEX=0
BONUS_INT=100
BONUS_STATS=25


[events e_raider] // you can also pass this event and add that functions under your custom player event.

on=@mount // player try to mount up
if (<src.riding> < <def.rid_<argo.baseid>>) // if skill is lower than animal got
    if (<r2> == 1) //fail
    timerf 1,src.sysmessage Hayvan sizi uzerinden atti.
    timerf 1,src.dismount
    endif
endif

serv.newitem i_dcsg // skill gainer and distance checker
src.equip <new>


on=@dismount
src.consume 999 i_dcsg

on=@userskills
src.sysmessage @07a1,,1 Riding Skilli : <src.riding>



[itemdef i_dcsg]
id i_gold
name Riding Skill
type t_eq_script

on=@create
attr attr_decay

on=@equip
timer 5
tag.ppos <cont.p>

on=@timer // properties.
if (<cont.riding> < <def.rid_<cont.findlayer.25.more1>>) // more fun :)
if (<r20> == 1)
cont.sysmessage @07a1,,1 Hayvanin hakimiyetini saglayamadiniz.
cont.dismount
endif
endif

if (<cont.riding> < 1000) && (<def.rid_<cont.findlayer.25.more1>> > <cont.riding>) // if skill bellow 100.0 and mount has more riding then player got
if (<distance <tag.ppos>> > 50) // distance have to move
if (<r5> == 1)
cont.riding +=1
cont.sysmessage @0120,,1 Riding Skilliniz 0.1 Yukselmistir.
tag.ppos <cont.p>
endif
endif
endif
timer 3
return 1

But still need fixes like ; when players use runebooks, moongates, telepads, ship planks whatever teleports the player have to reset i_dcsg tag.ppos otherwise player mount up recalls stay and wait for skill gain and loop.

[Image: riding.jpg]


RE: new skill riding - aptillah - 02-22-2014 01:47 AM

sphere have a error now like this ERROR:(riding.scp,83)Undefined symbol ''
if (<cont.riding> < 1000) && (<def.rid_<cont.findlayer.25.more1>> > <cont.riding>) in this line


RE: new skill riding - darksun84 - 02-22-2014 03:38 AM

try to use def0 instead of def


RE: new skill riding - amonvangrell - 02-22-2014 07:52 PM

This is such a good idea, I wonder y this skill is not in UO.
I'll add it to my shard as well...
Thanks man!


RE: new skill riding - Alaric - 02-22-2014 10:14 PM

(02-22-2014 07:52 PM)amonvangrell Wrote:  This is such a good idea, I wonder y this skill is not in UO.
I'll add it to my shard as well...
Thanks man!
Making afk script for this is much easier than mining or lumberjacking Tongue