Jump to content

How to create an item that spawns mobs/rb (ES/ENG version).


Recommended Posts

SPANISH VERSION (BELOW ENGLISH VERSION):

Buenas, después de tantos intentos, logre para OFF spawnear un rb mediante un ITEM, este método no es muy visto en los servidores actuales, es por eso que he decidido compartir esto con ustedes, espero que puedan darme los créditos <3.

 

Primero que nada, lo primero que todos sabemos es que hay muchos items o skills que spawnean objetos o summons, como los skills de necro o la flauta del dragon, tambien encontraremos otros en el ai.obj o en la programación base que tienen ciertas funciones para spawnear o sumonear.

 

Pero nos olvidamos que hay uno que especialmente spawnea un NPC por cierto tiempo, y este code se dedica a eso, estamos hablando del NPC de navidad, aunque en realidad es un ITEM que spawnea el NPC de navidad.

 

ID: 5560    ITEM NAME: Christmas Tree

 

Una vez sabiendo esto, para saber que tipo de skill usa este item, nos dirigimos a ItemData.txt (ubicado en script( y presionamos Ctrl + f, buscamos la ID 5560, automáticamente nos va a aparecer toda la información de este item:

 

item_begin    etcitem    5560    [x_mas_tree1]    item_type=etcitem    slot_bit_type={none}    armor_type=none    etcitem_type=potion    recipe_id=0    blessed=0    weight=0    default_action=action_skill_reduce    consume_type=consume_type_stackable    initial_count=1    maximum_count=20    soulshot_count=0    spiritshot_count=0    reduced_soulshot={}    reduced_spiritshot={}    reduced_mp_consume={}    immediate_effect=1    price=0    default_price=1    item_skill=[s_summon_x_mas_tree_a]   critical_attack_skill=[none]    attack_skill=[none]    magic_skill=[none]    item_skill_enchanted_four=[none]    material_type=paper    crystal_type=none    crystal_count=0    is_trade=1    is_drop=1    is_destruct=1    physical_damage=0    random_damage=0    weapon_type=none    can_penetrate=0    critical=0    hit_modify=0    avoid_modify=0    dual_fhit_rate=0    shield_defense=0    shield_defense_rate=0    attack_range=0    damage_range={}    attack_speed=0    reuse_delay=0    mp_consume=0    magical_damage=0    durability=0    damaged=0    physical_defense=0    magical_defense=0    mp_bonus=0    category={}    enchanted=0    html=[item_default.htm]    equip_pet={0}    magic_weapon=0    enchant_enable=0    can_equip_sex=-1    can_equip_race={}    can_equip_change_class=-1    can_equip_class={}    can_equip_agit=-1    can_equip_castle=-1    can_equip_castle_num={}    can_equip_clan_leader=-1    can_equip_clan_level=-1    can_equip_hero=-1    can_equip_nobless=-1    can_equip_chaotic=-1    item_end


Una vez que verificamos que skill esta usando (marcado en amarillo arriba), copiamos el nombre, en este caso es "item_skill=[s_summon_x_mas_tree_a]" -> "s_summon_x_mas_tree_a", realizamos el mismo proceso de busqueda, pero en este caso nos vamos al archivo llamado "SkilData.txt", lo abrimos y presionando Ctrl + F, buscamos s_summon_x_mas_tree_a.

 

Nos aparecera esta informacion, cabe aclarar que esta info es la creacion del skill y su efecto;

 

skill_begin    skill_name=[s_summon_x_mas_tree_a]    /* [쁼뀘 킸났 삌큘] */    skill_id=2137    level=1    operate_type=A1    magic_level=1    [color=yellow]effect={{i_summon_npc;[x_mas_tree_a];1}}[/color]    is_magic=0    mp_consume2=0    cast_range=-1    effective_range=-1    skill_hit_time=0    skill_cool_time=0    skill_hit_cancel_time=0    reuse_delay=0    attribute=attr_none    effect_point=0    target_type=self    affect_scope=single    affect_limit={0;0}    next_action=none    ride_state={@ride_none}    skill_end

 

Una vez encontrado, verán que hay una parte que dice "effect", esto seria que clase de llamado hace este skill, en este caso, esta llamando a spawnear un NPC (ustedes mismos pueden verificar el id de los skilles que quieran y buscarlos en este archivo, y veran los efectos), "effect={{i_summon_npc;[x_mas_tree_a];1}}".

 

[b]effect=[/b] -> hace referencia al efecto que va a producir
[b]{{i_summon_npc;[/b] -> hace referencia a que esta spawneando un npc.
[b][x_mas_tree_a];1[/b] -> hace refencia a la id del NPC entre corchetes y el ;1 hace referencia a la cantidad.  
 

una vez verificado esto, ahora ya tenemos la base para spawnear un mob, procederemos a hacer lo basico, crear un item con filedit (itemname, skillgrp, skillname, etc), en este caso les dejo el skillgrp/itemname/skillname:

EJEMPLOS DE COMO QUEDARIA:
 

skillgrp: 2138    1    0    0    -1    0    0.000000    0            icon.skill0000    0    0    0    0    -1    -1

skillname: 2138    1    Summon Special Boss    none    none    none

Itemname: 2138    Raid Boss - Random Bomb        Double-click to summon the Raid Boss. Beware: In case you move the raidboss into a peace zone, it will get despawned without warning!    -1                    0    0    0    

etcgrp: 2    2138    0    3    5    6    0    dropitems.drop_jewel_box_m00            dropitemstex.drop_jewel_box_t00            Raidboss.Bomb                    0    1    18    0    0    1        1        ItemSound.itemdrop_jewelbox        2    0    0

 

- Cambien las ID, porque son ID ramdoms. -


Una vez hecho esto, procedemos ir al DATAPACK, donde tendremos que crear el skill de 0 para que funcione correctamente, en mi caso, yo reemplace la id del npc del arbol y me funciona correctamente con ese item. Pero en este caso, lo que deberian hacer, es clonar el skilldata del arbol y el itemdata, es decir:


SKILLDATA:

 

skill_begin    skill_name=[s_NOMBRE_DE_SKILL]    /* [ꃠꀉ 킸났 삌큘] */    [skill_id=ID DEL SKILL    level=1    operate_type=A1    magic_level=1    effect={{i_summon_npc;[x_mas_tree_b];1}}    is_magic=0    mp_consume2=0    cast_range=-1    effective_range=-1    skill_hit_time=0    skill_cool_time=0    skill_hit_cancel_time=0    reuse_delay=0    attribute=attr_none    effect_point=0    target_type=self    affect_scope=single    affect_limit={0;0}    next_action=none    ride_state={@ride_none}    skill_end

 

ITEMDATA:

 

[code]item_begin    etcitem    (5560 ID DE ITEM)  [nombre_de_item]  item_type=etcitem    slot_bit_type={none}    armor_type=none    etcitem_type=potion    recipe_id=0    blessed=0    weight=0    default_action=action_skill_reduce    consume_type=consume_type_stackable    initial_count=1    maximum_count=20    soulshot_count=0    spiritshot_count=0    reduced_soulshot={}    reduced_spiritshot={}    reduced_mp_consume={}    immediate_effect=1    price=0    default_price=1    item_skill=[s_NOMBRE_DE_SKILL]    critical_attack_skill=[none]    attack_skill=[none]    magic_skill=[none]    item_skill_enchanted_four=[none]    material_type=paper    crystal_type=none    crystal_count=0    is_trade=1    is_drop=1    is_destruct=1    physical_damage=0    random_damage=0    weapon_type=none    can_penetrate=0    critical=0    hit_modify=0    avoid_modify=0    dual_fhit_rate=0    shield_defense=0    shield_defense_rate=0    attack_range=0    damage_range={}    attack_speed=0    reuse_delay=0    mp_consume=0    magical_damage=0    durability=0    damaged=0    physical_defense=0    magical_defense=0    mp_bonus=0    category={}    enchanted=0    html=[item_default.htm]    equip_pet={0}    magic_weapon=0    enchant_enable=0    can_equip_sex=-1    can_equip_race={}    can_equip_change_class=-1    can_equip_class={}    can_equip_agit=-1    can_equip_castle=-1    can_equip_castle_num={}    can_equip_clan_leader=-1    can_equip_clan_level=-1    can_equip_hero=-1    can_equip_nobless=-1    can_equip_chaotic=-1    item_end

 

SKILLPCH Y SKILLPCH2:

 

Deberan copiar el codigo de skilldata y meterlo en el "L2OFF GM PANEL", en donde lo tienen instalado, tienen un txt que se llama también "skilldata.txt", ahi pegan el codigo y guardan, luego de esto, abren el "L2OFF GM PANEL", tocando la opcion de "PCH Editor" y eso les abrira el generador, en el cual clickean "skilldata".
 

Les dejo imágenes para guiarse:
 

https://prnt.sc/qDghj9pL_I9d

https://gyazo.com/611a1bd80962cbadb56cec183ca50f28

https://gyazo.com/fe46c0b2e5f1a115aa541351640407e2


Espero que les haya servidor, att fa1thDEV/WaterColour.

-------------------------------------------------------------------------------------------------------------------------------------------

ENGLISH VERSION:


 

Good, after so many attempts, I managed to OFF spawn a rb using an ITEM, this method is not very seen in the current servers, that's why I decided to share this with you, I hope you can give me the credits <3.
 

First of all, the first thing we all know is that there are many items or skills that spawn objects or summons, like the necro skills or the dragon flute, we will also find others in the ai.obj or in the base programming that have certain functions to spawn or summon.
 

But we forget that there is one that especially spawns an NPC for a certain time, and this code is dedicated to that, we are talking about the Christmas NPC, although it is actually an ITEM that spawns the Christmas NPC.

 

ID: 5560    ITEM NAME: Christmas Tree

Once we know this, to know what type of skill this item uses, we go to ItemData.txt (located in script and press Ctrl + f, we look for the ID 5560, automatically all the information of this item will appear:

item_begin    etcitem    5560    [x_mas_tree1]    item_type=etcitem    slot_bit_type={none}    armor_type=none    etcitem_type=potion    recipe_id=0    blessed=0    weight=0    default_action=action_skill_reduce    consume_type=consume_type_stackable    initial_count=1    maximum_count=20    soulshot_count=0    spiritshot_count=0    reduced_soulshot={}    reduced_spiritshot={}    reduced_mp_consume={}    immediate_effect=1    price=0    default_price=1    item_skill=[s_summon_x_mas_tree_a]   critical_attack_skill=[none]    attack_skill=[none]    magic_skill=[none]    item_skill_enchanted_four=[none]    material_type=paper    crystal_type=none    crystal_count=0    is_trade=1    is_drop=1    is_destruct=1    physical_damage=0    random_damage=0    weapon_type=none    can_penetrate=0    critical=0    hit_modify=0    avoid_modify=0    dual_fhit_rate=0    shield_defense=0    shield_defense_rate=0    attack_range=0    damage_range={}    attack_speed=0    reuse_delay=0    mp_consume=0    magical_damage=0    durability=0    damaged=0    physical_defense=0    magical_defense=0    mp_bonus=0    category={}    enchanted=0    html=[item_default.htm]    equip_pet={0}    magic_weapon=0    enchant_enable=0    can_equip_sex=-1    can_equip_race={}    can_equip_change_class=-1    can_equip_class={}    can_equip_agit=-1    can_equip_castle=-1    can_equip_castle_num={}    can_equip_clan_leader=-1    can_equip_clan_level=-1    can_equip_hero=-1    can_equip_nobless=-1    can_equip_chaotic=-1    item_end
 

Once we verify which skill is being used (marked in yellow above), we copy the name, in this case it is "item_skill=[s_summon_x_mas_tree_a]" -> "item_skill=[s_summon_x_mas_tree_a]". -> "s_summon_x_mas_tree_a", we make the same search process, but in this case we go to the file called "SkilData.txt", we open it and pressing Ctrl + F, we look for s_summon_x_mas_tree_a.
 

This information will appear, it is important to clarify that this info is the creation of the skill and its effect;

skill_begin    skill_name=[s_summon_x_mas_tree_a]    /* [쁼뀘 킸났 삌큘] */    skill_id=2137    level=1    operate_type=A1    magic_level=1    effect={{i_summon_npc;[x_mas_tree_a];1}}    is_magic=0    mp_consume2=0    cast_range=-1    effective_range=-1    skill_hit_time=0    skill_cool_time=0    skill_hit_cancel_time=0    reuse_delay=0    attribute=attr_none    effect_point=0    target_type=self    affect_scope=single    affect_limit={0;0}    next_action=none    ride_state={@ride_none}    skill_end
 

Once found, you will see that there is a part that says "effect", this would be what kind of call this skill makes, in this case, it is calling to spawn an NPC (you can check the id of the skills you want and look for them in this file, and you will see the effects), "effect={{i_summon_npc;[x_mas_tree_a];1}}".
 

effect= -> refers to the effect you are going to produce.
{{i_summon_npc; -> refers to spawning an npc.
[x_mas_tree_a];1 -> refers to the NPC id in square brackets and the ;1 refers to the amount.  
 

once verified this, now we have the base to spawn a mob, we will proceed to do the basics, create an item with filedit (itemname, skillgrp, skillname, etc), in this case I leave you the skillgrp/itemname/skillname:

EXAMPLES HOW:
 

skillgrp: 2138    1    0    0    -1    0    0.000000    0            icon.skill0000    0    0    0    0    -1    -1

skillname: 2138    1    Summon Special Boss    none    none    none

Itemname: 2138    Raid Boss - Random Bomb        Double-click to summon the Raid Boss. Beware: In case you move the raidboss into a peace zone, it will get despawned without warning!    -1                    0    0    0    

etcgrp: 2    2138    0    3    5    6    0    dropitems.drop_jewel_box_m00            dropitemstex.drop_jewel_box_t00            Raidboss.Bomb                    0    1    18    0    0    1        1        ItemSound.itemdrop_jewelbox        2    0    0

 

- Change the IDs, because they are ID ramdoms. -


Once this is done, we proceed to DATAPACK, where we will have to create the skill from 0 to work correctly, in my case, I replaced the id of the npc of the tree and it works correctly with that item. But in this case, what you should do, is to clone the skilldata of the tree and the itemdata, that is to say:

 

SKILLDATA:

 

skill_begin    skill_name=[s_Name_SKILL]    /* [ꃠꀉ 킸났 삌큘] */    [skill_id=ID_SKILL    level=1    operate_type=A1    magic_level=1    effect={{i_summon_npc;[x_mas_tree_b];1}}    is_magic=0    mp_consume2=0    cast_range=-1    effective_range=-1    skill_hit_time=0    skill_cool_time=0    skill_hit_cancel_time=0    reuse_delay=0    attribute=attr_none    effect_point=0    target_type=self    affect_scope=single    affect_limit={0;0}    next_action=none    ride_state={@ride_none}    skill_end

 

ITEMDATA:

 

[code]item_begin    etcitem    (5560 ID ITEM)  [name_item]  item_type=etcitem    slot_bit_type={none}    armor_type=none    etcitem_type=potion    recipe_id=0    blessed=0    weight=0    default_action=action_skill_reduce    consume_type=consume_type_stackable    initial_count=1    maximum_count=20    soulshot_count=0    spiritshot_count=0    reduced_soulshot={}    reduced_spiritshot={}    reduced_mp_consume={}    immediate_effect=1    price=0    default_price=1    item_skill=[s_name_SKILL]    critical_attack_skill=[none]    attack_skill=[none]    magic_skill=[none]    item_skill_enchanted_four=[none]    material_type=paper    crystal_type=none    crystal_count=0    is_trade=1    is_drop=1    is_destruct=1    physical_damage=0    random_damage=0    weapon_type=none    can_penetrate=0    critical=0    hit_modify=0    avoid_modify=0    dual_fhit_rate=0    shield_defense=0    shield_defense_rate=0    attack_range=0    damage_range={}    attack_speed=0    reuse_delay=0    mp_consume=0    magical_damage=0    durability=0    damaged=0    physical_defense=0    magical_defense=0    mp_bonus=0    category={}    enchanted=0    html=[item_default.htm]    equip_pet={0}    magic_weapon=0    enchant_enable=0    can_equip_sex=-1    can_equip_race={}    can_equip_change_class=-1    can_equip_class={}    can_equip_agit=-1    can_equip_castle=-1    can_equip_castle_num={}    can_equip_clan_leader=-1    can_equip_clan_level=-1    can_equip_hero=-1    can_equip_nobless=-1    can_equip_chaotic=-1    item_end

 

SKILLPCH Y SKILLPCH2:


You should copy the code of skilldata and put it in the "L2OFF GM PANEL", where you have it installed, you have a txt that is also called "skilldata.txt", there paste the code and save, after this, open the "L2OFF GM PANEL", touching the option of "PCH Editor" and that will open the generator, in which you click "skilldata".


I leave images to guide you:


https://prnt.sc/qDghj9pL_I9d

https://gyazo.com/611a1bd80962cbadb56cec183ca50f28

https://gyazo.com/fe46c0b2e5f1a115aa541351640407e2

I hope you found it useful, att fa1thDEV/WaterColour.

BTW!, if there is any error, I am more than willing to fix or collaborate, greetings!

Edited by fa1thDEV
  • Like 1
Link to comment
Share on other sites

  • fa1thDEV changed the title to How to create an item that spawns mobs/rb (ES/ENG version).

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now


×
×
  • Create New...