Jump to content
  • 0
Sign in to follow this  
chrizz

Pet Problem

Question

Hi,

i run 34k files and 36469bin.

 

pet Quest is here:

    quest pet_system begin
        state start begin
            function get_pet_info(itemVnum)
                pet_info_map = {
                --  [ITEM VNUM] MOB_VNUM, DEFAULT NAME, buff_idx, spawn_effect_idx
                    [53001]     = { 34001, "'s Feuer Phoenix", 0},
                    [53002]     = { 34002, "'s Baby Reindeer", 0},
                    [53003]     = { 34003, "'s Eis Phoenix", 0},
                    [53004]     = { 34001, "'s Feuer Phoenix", 0},
                    [53005]     = { 34004, "'s Baby Gahnasel", 1},
                    [53006]     = { 34009, "'s Golden Gahnasel", 1},
                    [53007]     = { 34010, "'s Bambi", 0},
                    [53008]     = { 34011, "'s Knuud", 0},
                    [53009]     = { 34012, "'s Bao Bao", 0},
                    [53010]     = { 34008, "'s Leonidas", 0},
                    [53011]     = { 34007, "'s Khan", 0},
                    [53012]     = { 34005, "´s Porky", 0},
                    [53013]     = { 34006, "´s Rufus", 0},
                }
     
                itemVnum = tonumber(itemVnum)
     
                return pet_info_map[itemVnum]
            end
                    function get_spawn_effect_file(idx)
                            effect_table = {
                                    [0] = nil,
                                    [1] = "d:ymir workeffectetcappear_dienpc2_appear.mse",
                            }
                            return effect_table [idx]
                    end
            when 53001.use or
                             53002.use or
                             53003.use or
                             53004.use or
                             53005.use or
                             53006.use or
                             53007.use or
                             53008.use or
                             53009.use or
                             53010.use or
                             53011.use or
                             53012.use or
                             53013.use begin
                             local pet_info = pet_system.get_pet_info(item.vnum)
     
                if null != pet_info then
     
                    local mobVnum = pet_info[1]
                    local petName = pet_info[2]
                                    local spawn_effect_file_name = pet_system.get_spawn_effect_file(pet_info[3])
     
                    if true == pet.is_summon(mobVnum) then
                                            if spawn_effect_file_name != nil then
                                                    pet.spawn_effect (mobVnum, spawn_effect_file_name)
                                            end
                        pet.unsummon(mobVnum)
                    else
                        if pet.count_summoned() < 1 then
                            pet.summon(mobVnum, petName, false)
                        else
                            syschat("You already summoned a pet.")
                        end
                                            if spawn_effect_file_name != nil then
                                                    pet.spawn_effect (mobVnum, spawn_effect_file_name)
                                            end
                    end -- if pet.is_summon
                end  -- if null != pet_info
            end -- when
        end -- state
    end -- quest

All pets are working when i call them with /m XXXX

 

Seal is type 18  (for quest to click it)

 

Quest compile with 0 Error.

 

When i click ingame on Seal nothing happens.

 

 

what can be the Problem?.

syslog of ch1

Mar 15 19:25:14 :: [SGA]chrizz: USE_ITEM Phoenix-Siegel (cell: 9)

Share this post


Link to post

1 answer to this question

Recommended Posts

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.