;;;QQ:67762207
[@HorseSystem]
{
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}Welcome to the stables. Horse prices are very expensive, please buy carefully.\\
<[Buy]/@BuyHorse(BrownHorse,15,500000)> Brown Horse{FCOLOR/2}(500000 GoldLevel 15)\
<[Buy]/@BuyHorse(WhiteHorse,40,20000000)> {FCOLOR/10}White Horse{FCOLOR/12}{FCOLOR/2}(20000000 GoldLevel 40)\
<[Buy]/@BuyHorse(BlackHorse,60,90000000)> {FCOLOR/10}Black Horse{FCOLOR/12}{FCOLOR/2}(90000000 Gold,Level 60)\
<[Buy]/@BuyJiFenhorse(,60000,70)> {FCOLOR/10}Red Horse{FCOLOR/12}{FCOLOR/2}(60000 Gamepoints,Level 70)\
<[Buy]/@BuyJiFenhorse(Ӱ,80000,80)> {FCOLOR/10}Armoured Horse{FCOLOR/12}{FCOLOR/2}(80000 Gamepoints,Level 80)\\
;<Ask/@ASKJueYing> About Armoured Horse \
<[Sell Horse]/@SellHorse> \
<[Cancle]/@exit>




[@BuyNewhorse]
#IF
#ACT
mov IntroCDKEY ""
mov GetHorse 0
formatstr "where fld_userid = '%s'" %USERID
actcmd READSQL "TBL_Promoters" "IntroCDKEY,GetHorse" "IntroCDKEY,GetHorse" %A9



#IF
!CheckHorse
#ELSEACT
break
#ELSESAY
Բӵ\\
</@main>




#IF
EQUAL GetHorse 1
!EQUAL IntroCDKEY ""
checklevel 75
!CheckHorse
checkcmd CHECKUSERJF 300
#ACT
horsecall ArmouredHorse
actcmd SETUSERJF - 300 ArmouredHorse
break
#SAY
ȻдCDKEYҲﵽ75Ѿһѵˡ\
Աʹ300Gamepoints {FCOLOR/14}ǧ{FCOLOR/12} ArmouredHorse\\
<뿪/@exit>


#IF
EQUAL GetHorse 0
!EQUAL IntroCDKEY ""
checklevel 75
!CheckHorse
#ACT
break
horsecall ArmouredHorse
formatstr "where fld_userid = '%s'" %USERID
actcmd WRITESQL "TBL_Promoters" "GetHorse" 1 %A9
#SAY
ΪдCDKEYҲﵽ75㽫ѻһƥ {FCOLOR/14}ǧ{FCOLOR/12} ArmouredHorse\\
<뿪/@exit>

#IF
EQUAL IntroCDKEY ""
ELarge USERREBORNCOUNT 5
checkcmd CHECKUSERJF 1000
#ACT
horsecall ArmouredHorse
actcmd SETUSERJF - 1000 ArmouredHorse
break
#SAY
ΪûдCDKEYʹ1000Gamepoints.\
 {FCOLOR/14}ǧ{FCOLOR/12} ArmouredHorse\\
<뿪/@exit>

#IF
#SAY
Բв㹺˾.\\
<뿪/@exit>



[@ASKJueYing]
#IF
#SAY
˵ͨϵͳҿԵõ귩½ĹԱ͵һƥ.\
ArmouredHorseܹ250\
25㹥22Ȼϵħ\
ָٶȱƥԿһЩ\\
<ôܵõƥأ/@Askjueying_2>

[@Askjueying_2]
#IF
#SAY
\
ӦӵCDKEYȡ\
ôﵽ涨ȼʱ\
Ϳȡսˡ\\
ӵCDKEYֱҹԱˣ\
ֻ͸¶ôˣԼˡ\

</@horsesystem>






[@BuyJiFenhorse()]
#ACT
mov A0 %ARG(1)
mov D0 %ARG(2)
mov D1 %ARG(3)

#IF
checklevel %D1
#ELSEACT
break
#ELSESAY
Բûдﵽ<$OUTPUT(D1)>ܼԦĺ\
</@main>
#IF
checkcmd CHECKUSERJF %D0
#ELSEACT
break
#ELSESAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You do not have <$OUTPUT(D0)> Gamepoints.\
<[Return]/@main>

#IF
CheckHorse
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You already have a horse, Please sell the one you have already.\
<[Return]/@main>
#ELSEACT
goto @Buyredhorse_3

[@Buyredhorse_3]
#IF
checklevel %D1
checkcmd CHECKUSERJF %D0
#ACT
horsecall %A0
actcmd SETUSERJF - %D0 %A0
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}Successful purchase, Your remaining gamepoints: {FCOLOR/1}<$USERJF>{FCOLOR/12}\
{FCOLOR/2}To mount your horse press 'M'.\
<[Return]/@main>


#ELSESAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You only have {FCOLOR/1}<$USERJF>{FCOLOR/12}{FCOLOR/2} Gamepoints.\
{FCOLOR/2}Or You are not level 70.\
<[Close]/@exit>




[@BuyHorse()]
#IF
#ACT
Mov A0 %ARG(1)
Mov D0 %ARG(2)
Mov D1 %ARG(3)

#IF
checklevel %D0
#ELSESAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/10}Only Level <$OUTPUT(D0)> and above{FCOLOR/12} {FCOLOR/2}can buy <$OUTPUT(A0)>.\\
<[Close]/@exit>
#ELSEACT
break

#IF
checkgold %D1
#ELSESAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You dont have <$OUTPUT(D1)> Gold for <$OUTPUT(A0)>.\\
<[Close]/@exit>
#ELSEACT
break

#IF
CheckHorse
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You already have a horse.\\
<[Close]/@exit>
#ACT
break

#IF
checklevel %D0
checkgold %D1
!CheckHorse
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}<$OUTPUT(A0)> is now yours, please take care of it.\\
<[Close]/@exit>
#ACT
take Gold %D1
horsecall %A0
break

[@SellHorse]
#IF
checkhorse 1
!CheckRiding
!CheckGold 999749999
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You sold BrownHorse, here is your reward.\\
<[Close]/@exit>
#ACT
actcmd givegoldex 250000
KillHorse
break

#IF
checkhorse 2
!CheckRiding
!CheckGold 989999999
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You sold WhiteHorse, here is your reward.\\
<[Close]/@exit>
#ACT
actcmd givegoldex 10000000
KillHorse
break

#IF
checkhorse 3
!CheckRiding
!CheckGold 944999999
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You sold RedHorse, here is your reward.\\
<[Close]/@exit>
#ACT
actcmd givegoldex 45000000
KillHorse
break

#IF
checkhorse 4
!CheckRiding
!CheckGold 944999999
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}You sold BlackHorse, here is your reward.\\
<[Close]/@exit>
#ACT
actcmd givegoldex 45000000
KillHorse
break

#IF
checkhorse 5
!CheckRiding
!CheckGold 909999999
#SAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}Sold ArmouredHorse, here is your reward.\\
<[Close]/@exit>
#ACT
actcmd givegoldex 90000000
KillHorse
break


#ELSESAY
_______________{FCOLOR/1}[{FCOLOR/12} {FCOLOR/14}NPC Functions{FCOLOR/12} {FCOLOR/1}]{FCOLOR/12} \\
{FCOLOR/2}Cannot sell horse because you dont own one or your are currently mounted.\\
<[Close]/@exit>
}
;;-----------------------------aragom
