Jump to content

jKing

Member
  • Posts

    29
  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by jKing

  1. Check 

    bool CHARACTER::IsImmune(DWORD dwImmuneFlag)

    in char_resist.cpp

    Also make shure to put immune_flags in correct order in setImmuneFlag in mob_proto. For example if you have enum:
     

    	IMMUNE_STUN = (1 << 0),
    	IMMUNE_SLOW = (1 << 1),
    	IMMUNE_FALL = (1 << 2),
    	IMMUNE_CURSE = (1 << 3),
    	IMMUNE_POISON = (1 << 4),
    	IMMUNE_TERROR = (1 << 5),
    	IMMUNE_REFLECT = (1 << 6),

    then immune_stun should be firsst, next slow etc. It cannot be like

    IMMUNE_POISON | IMMUNE_CURSE | IMMUNE_TERROR

     

  2. Put your translations into locale_game.txt (in locale folder) and use it like localeInfo.YOUR_STRING -> use localeInfo inside root scripts (remember about import)

    If you want text in uiscript (ui_jack_kingdom in your case) use locale_interface.txt, import uiScriptLocale and use it like. uiScriptLocale.YOUR_STRING

     

    Example:

    locale_interface.txt 
     

    MY_TEXT[TAB]There goes your translation in polish


    In your script:

    import uiScriptLocale
    (...)
    {
    	"name" : "text_kingdom_01_01", "type" : "text",
    	"x" : 223 / 2 + 22, "y" : 155+18*0,
    	"text_horizontal_align" : "center",
    	"fontname" : "Tahoma:13",
    	"color" : 0xffCECECE,
    	"text" : uiScriptLocale.MY_TEXT,
    },
    (...)
  3. 46 minut temu, Sirio napisał:

    In char_skill.cpp, under:

    
    bool CHARACTER::UseSkill(DWORD dwVnum, LPCHARACTER pkVictim, bool bUseGrandMaster)
    {
    	if (false == CanUseSkill(dwVnum))
    		return false;

    paste:

    
    	int iArrayIndexSkill[] = {94, 95, 96, 109, 110, 111}; // skill index
    
    	for (int iBuffSkill = 0; iBuffSkill < _countof(iArrayIndexSkill); iBuffSkill++)
    	{
    		if (iArrayIndexSkill[iBuffSkill] == dwVnum && pkVictim->GetMapIndex() == 26) // map index
    		{
    			ChatPacket(CHAT_TYPE_INFO, LC_TEXT("Say something."));
    			pkVictim = this;
    		} 
    	}

     

    Not my code, but i forgot who it is.

    Thank you! It works fine, but its a one little problem. When i buff myself on specify map LC_TEXT is showing. Is there a option to showing LC_TEXT only when im trying to buff other player?

  4. Hello guys, i used this theard: 

    all works fine, but i have 2 problems:

    1) When i change channel, its works, but under minimap is still CH1 (when im on ch2 for example)

    2) The information: "You're already in the selected channel!" works only on CH1, for example, im on CH1, trying to change channel to CH1, information works, but when im on CH2 and trying change to CH1 there is that information and i cant change channel.

    I know its hard to understand me, but i hope u will help me, sorry for bad english guys

  5. How should I edit that quest to don't unsummon pet after teleport?


    -- # --------------------------------------------- #
    -- #  Questfile from Metin2SF by Terenzo  #
    -- # --------------------------------------------- #

    quest pet_system begin
        state start begin
            function get_pet_info(itemVnum)
                pet_info_map = {
                    [53001] = {34001, "- Ognisty Feniks", 0},
                    [53002] = {34002, "- Reniferek", 0},
                    [53003] = {34003, "- Lodowy Feniks", 0},
                    [53005] = {34004, "- Azraeluś ", 1},
                    [53006] = {34027, "- Smoczek ", 1},
                    [53007] = {34010, " - Bambi", 0},
                    [53008] = {34011, "- Knuud", 0},
                    [53009] = {34012, "- Bao Bao", 0},
                    [53010] = {34008, "- Lwiątko", 0},
                    [53011] = {34007, "- Tygrysek", 0},
                    [53012] = {34005, "- Świnka ", 0},
                    [53013] = {34006, "- Piesek", 0},
                }
                itemVnum = tonumber(itemVnum)
                return pet_info_map[itemVnum]
            end
            function get_spawn_effect_file(idx)
                effect_table = {
                    [0] = nil,
                    [1] = "d:\\\\ymir work\\\\effect\\\\etc\\\\appear_die\\\\npc2_appear.mse",
                }
                return effect_table [idx]
            end
            when 53001.use or 53002.use or 53003.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 or pc.is_gm() then
                            pet.summon(mobVnum, " ".. petName, false)
                        else
                            syschat("Nie możesz przywołać kilku zwierzaków.")
                        end
                        if spawn_effect_file_name != nil then
                            pet.spawn_effect(mobVnum, spawn_effect_file_name)
                        end
                    end
                end
            end
        end
    end

     

×
×
  • 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.