Post Pacific

Post Pacific (https://postpacific.loc-online.com/index.php)
-   Темы без сохранившегося раздела (https://postpacific.loc-online.com/forumdisplay.php?f=10001)
-   -   Heart of warding (https://postpacific.loc-online.com/showthread.php?t=1814)

Drew 15.09.2005 09:44

Heart of warding
 
I have a problem with heart_of_warding and teleporting to Antaras. Hving portal stone in my qwest items it doesn't teleport me to Antaras Nest. I'm not very good in AI codding, but my AI for heart_of_warding looks like this:
Code:

class ai_boss04_heart_of_warding : default_npc
handler 3        //  TALKED
        variable_begin
                "talker"
                "myself"
                "_choiceN"
                "_code"
                "_from_choice"
        variable_end

        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
S455.        "heart_of_warding001.htm"
        push_string S455
        func_call 43        //  func[ShowPage]
        shift_sp -2
        shift_sp -1
handler_end

handler 28        //  TELEPORT_REQUESTED
        variable_begin
                "talker"
                "i0"
                "c0"
                "i1"
                "i2"
                "myself"
                "_choiceN"
                "_code"
                "_from_choice"
        variable_end

        push_event        //  i0
        push_const 192
        add
        push_reg_sp
        fetch_i
        shift_sp 1
        push_const 1
        func_call 33        //  func[GetGlobalMap]
        shift_sp -1
        assign
        shift_sp -1
        push_event        //  i0
        push_const 192
        add
        fetch_i
        push_const 1
        negate
        not_equal
        branch_false L3756
L3755
        push_event        //  c0
        push_const 272
        add
        push_reg_sp
        fetch_i
        shift_sp 1
        push_event        //  i0
        push_const 192
        add
        fetch_i
        func_call 30        //  func[GetCreatureFromIndex]
        shift_sp -1
        assign
        shift_sp -1
        push_event        //  c0
        push_const 272
        add
        fetch_i        //  alive
        push_const 112
        add
        fetch_i
        branch_false L3758
L3757
        push_event        //  c0
        push_const 272
        add
        fetch_i        //  db_value
        push_const 1892
        add
        fetch_i
        push_const 0
        equal
        push_reg_sp
        fetch_i
        branch_true L3759
        push_event        //  c0
        push_const 272
        add
        fetch_i        //  db_value
        push_const 1892
        add
        fetch_i
        push_const 1
        equal
        or
L3759
        branch_false L3761
L3760
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
        push_const 3865
        func_call 81        //  func[OwnItemCount]
        shift_sp -2
        push_const 0
        greater
        branch_false L3763
L3762
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
        push_const 3865
        push_const 1
        func_call 80        //  func[DeleteItem1]
        shift_sp -3
        shift_sp -1
        shift_sp 1
        push_event        //  c0
        push_const 272
        add
        fetch_i
        push_const 0
        push_const 0
        func_call 34        //  func[SendScriptEvent]
        shift_sp -3
        shift_sp -1
        push_event        //  i1
        push_const 196
        add
        push_reg_sp
        fetch_i
        push_const 179700
        shift_sp 1
        push_const 700
        func_call 55        //  func[Rand]
        shift_sp -1
        add
        assign
        shift_sp -1
        push_event        //  i2
        push_const 200
        add
        push_reg_sp
        fetch_i
        push_const 113800
        shift_sp 1
        push_const 2100
        func_call 55        //  func[Rand]
        shift_sp -1
        add
        assign
        shift_sp -1
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
        push_event        //  i1
        push_const 196
        add
        fetch_i
        push_event        //  i2
        push_const 200
        add
        fetch_i
        push_const 7709
        negate
        func_call 46        //  func[InstantTeleport]
        shift_sp -4
        shift_sp -1
        jump L3764
L3763
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
S456.        "heart_of_warding004.htm"
        push_string S456
        func_call 43        //  func[ShowPage]
        shift_sp -2
        shift_sp -1
L3764
        jump L3765
L3761
        push_event        //  c0
        push_const 272
        add
        fetch_i        //  db_value
        push_const 1892
        add
        fetch_i
        push_const 2
        equal
        push_reg_sp
        fetch_i
        branch_true L3766
        push_event        //  c0
        push_const 272
        add
        fetch_i        //  db_value
        push_const 1892
        add
        fetch_i
        push_const 3
        equal
        or
L3766
        branch_false L3768
L3767
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
S457.        "heart_of_warding003.htm"
        push_string S457
        func_call 43        //  func[ShowPage]
        shift_sp -2
        shift_sp -1
L3768
L3765
        jump L3769
L3758
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
S458.        "heart_of_warding002.htm"
        push_string S458
        func_call 43        //  func[ShowPage]
        shift_sp -2
        shift_sp -1
L3769
        jump L3770
L3756
        shift_sp 1
        push_event        //  talker
        push_const 32
        add
        fetch_i
S459.        "heart_of_warding002.htm"
        push_string S459
        func_call 43        //  func[ShowPage]
        shift_sp -2
        shift_sp -1
L3770
handler_end

class_end

As I can know, all teleporters should have coordinates where to teleport to. I can't find ones here. In npcdata there're some coordinates for Antaras but I can't get there using GM and command //teleport [coordinates]. It says "wrong coordinates" like there no such coordinates at all.

maximus 15.09.2005 19:08

I have the same problem.. :(


All times are GMT. The time now is 15:40.