Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- quest ride begin
- state start begin
- function Ride( vnum, remain_time )
- ride_info = {
- [71137] = { 29376, 60*60*24*365, apply.ATTBONUS_MONSTER, 0, 0, false, false },
- [71138] = { 29376, 60*60*24*365, apply.MALL_EXPBONUS, 0, 0, true, true },
- [71139] = { 29376, 60*60*24*365, apply.MAX_HP, 0, 0, false, false },
- [71140] = { 29376, 60*60*24*365, apply.DEF_GRADE_BONUS, 0, 0, false, true },
- [71141] = { 29376, 60*60*24*365, apply.ATT_GRADE_BONUS, 0, 0, false, true },
- [71142] = { 29376, 60*60*24*365, apply.ATTBONUS_MONSTER, 3, 0, false, true },
- }
- if pc.level < ride_info[vnum][5] then
- chat("<Wierzchowiec> Nie jesteś wystarczająco doświadczony, by dosiąść tego wierzchowca...")
- else
- if ride_info[vnum][2] == 0 and remain_time != 0 then
- pc.mount( ride_info[vnum][1], remain_time*60 )
- pc.mount_bonus( ride_info[vnum][3], ride_info[vnum][4], remain_time*60 )
- else
- pc.mount( ride_info[vnum][1], ride_info[vnum][2] )
- pc.mount_bonus( ride_info[vnum][3], ride_info[vnum][4], ride_info[vnum][2] )
- end
- if true == ride_info[vnum][6] then
- pc.remove_item(vnum, 1)
- end
- end
- end
- when login begin
- local vnum, remain_time = pc.get_special_ride_vnum()
- if 0 != vnum then
- ride.Ride(vnum, remain_time)
- end
- end
- when 71137.use or 71138.use or 71139.use or
- 71140.use or 71141.use or 71152.use begin
- if pc.is_polymorphed() then
- chat("<Wierzchowiec> Nie możesz dosiąść wierzchowca będąc przemienionym.")
- elseif false == pc.is_mount() then
- if true == horse.is_summon() then
- horse.unsummon()
- end
- item.set_socket(2, 60*24*365*60)
- ride.Ride(item.vnum, 0)
- else
- pc.unmount()
- end
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement