Jump to content

wend

Members
  • Posts

    13
  • Joined

  • Last visited

Posts posted by wend

  1. I try to add custom guild skill, but it's not shown in game.

     

    what I did:

     

    1. in mmo.h increased MAX_GUILDSKILL to 17 and add GD_CUSTOM=10016, before GD_MAX

    2. added line

    10016,1,0,0,0,0,0,0,0,0,0,0
    

    to guild_skill_tree.txt

     

    3. added line

    10017,0,0,0,0,0,0,1,0,no,0,0x10,0,none,0,    GD_CUSTOM,Custom Skill
     

    to skill_db.txt

     

    4. added GD_CUSTOM = 10017, to skillid.lua

    5. added

        [SKID.GD_CUSTOM] = {
    
            "Custom Skill.",
        },
     

     

    to skilldescript.lua

     

    6. added

         [SKID.GD_CUSTOM] = {
            "GD_CUSTOM";
            SkillName = "Custom Skill",
            MaxLv = 1,
            SpAmount = { 0 },
            bSeperateLv = false,
            AttackRange = { 1 }
        },
    

    to skillinfolist.lua

     

     

    please help me with this :(

  2. I created custom instance, when I use the existing map for it ( like 1@orcs, 1@tower etc. ) everything works fine, but when I use my map (1@test) or any other map with emulation (instance_attachmap("aru_gld", .@instance, 1) everything works fine too, but i get debug message from char-server:

    [01/Jun 12:09][Debug]: mapindex_id2name: Requested name for non-existant map index [841] in cache.

    map_cache.dat contains 840 maps.

    need help with this.

  3. source:

    static int bg_team_db_reset(DBKey key, void *data, va_list ap)
    {
    struct battleground_data *bg = (struct battleground_data *)data;
    bg_team_clean(bg->bg_id,false);
    return 0;
    }
    
    static int queue_db_final(DBKey key, void *data, va_list ap)
    {
    struct queue_data *qd = (struct queue_data *)data;
    queue_members_clean(qd); // Unlink all queue members
    return 0;
    }
    
    void bg_reload(void)
    { // @reloadscript
    bg_team_db->destroy(bg_team_db,bg_team_db_reset);	//line 878
    queue_db->destroy(queue_db, queue_db_final);		//line 879
    
    bg_team_db = idb_alloc(DB_OPT_RELEASE_DATA);
    queue_db = idb_alloc(DB_OPT_RELEASE_DATA);
    
    bg_team_counter = 0;
    queue_counter = 0;
    }
    
    void do_final_battleground(void)
    {
    bg_team_db->destroy(bg_team_db, NULL);
    queue_db->destroy(queue_db, queue_db_final);		//line 891
    }

    Compilation (Debian):

    battleground.c: In function 'bg_reload':
    battleground.c:878: warning: passing argument 2 of 'bg_team_db->destroy' from incompatible pointer type
    battleground.c:878: note: expected 'DBApply' but argument is of type 'int (*)(union DBKey,  void *, struct __va_list_tag *)'
    battleground.c:879: warning: passing argument 2 of 'queue_db->destroy' from incompatible pointer type
    battleground.c:879: note: expected 'DBApply' but argument is of type 'int (*)(union DBKey,  void *, struct __va_list_tag *)'
    battleground.c: In function 'do_final_battleground':
    battleground.c:891: warning: passing argument 2 of 'queue_db->destroy' from incompatible pointer type
    battleground.c:891: note: expected 'DBApply' but argument is of type 'int (*)(union DBKey,  void *, struct __va_list_tag *)'

    At shutdown:

    [Warning]: ers::destroy : 14498 entries missing (possible double free), continuing destruction (entry size=32).

    How to fix it?

×
×
  • Create New...