How to make suprice box?

Blood Tears

Путник
Пользователь
Сообщения
30
Розыгрыши
0
Репутация
-8
Реакции
2
Баллы
0
Hi all, i want to make suprice box with rewards. For example when you click 2 times on the box, and to open chat and to show:
Farm coins (50) - 100%
Adena 1kk - 50%
Enria (1) - 20%

I need this for acis
 
Посмотри как реализован квест на реагенты. Как в ИТ был еще нужен был для масла и че-то там еще на нубл.
 
<skill id="2174" levels="3" name="Ingredient Bag">
<!-- Confirmed CT2.5 -->
<table name="#extractableItems">
6019,2,30;6013,2,30;6014,1,20;6016,1,20
6017,2,10;6020,2,20;6014,1,35;6016,1,35
6012,1,20;6018,2,20;6019,2,20;6013,1,40
</table>
<set name="capsuled_items_skill" val="#extractableItems" />
<set name="isMagic" val="2" /> <!-- Static Skill -->
<set name="magicLvl" val="1" />
<set name="operateType" val="A1" />
<set name="rideState" val="NONE;STRIDER;WYVERN;WOLF" />
<set name="targetType" val="SELF" />
<cond msgId="129">
<and>
<player invSize="10" />
<player weight="80" />
</and>
</cond>
<for>
<effect name="RestorationRandom" />
</for>
</skill>
 
<skill id="2174" levels="3" name="Ingredient Bag">
<!-- Confirmed CT2.5 -->
<table name="#extractableItems">
6019,2,30;6013,2,30;6014,1,20;6016,1,20
6017,2,10;6020,2,20;6014,1,35;6016,1,35
6012,1,20;6018,2,20;6019,2,20;6013,1,40
</table>
<set name="capsuled_items_skill" val="#extractableItems" />
<set name="isMagic" val="2" /> <!-- Static Skill -->
<set name="magicLvl" val="1" />
<set name="operateType" val="A1" />
<set name="rideState" val="NONE;STRIDER;WYVERN;WOLF" />
<set name="targetType" val="SELF" />
<cond msgId="129">
<and>
<player invSize="10" />
<player weight="80" />
</and>
</cond>
<for>
<effect name="RestorationRandom" />
</for>
</skill>
Спасиба, but i need a java code for this, i have tryed it but it dont work.
 
You can find nice example in your code.
For example, you can use code from this quest
item

Hallate's Maid Reagent Pouch opens into:
  • 2x etc_reagent_silver_i00.png Quicksilver 30%
  • 2x etc_broken_crystal_silver_i00.png Moonstone Shard 30%
  • 1x etc_piece_bone_black_i00.png Rotten Bone Piece 20%
  • 1x etc_inf_ore_least_i00.png Infernium Ore 20%
 
You can find nice example in your code.
For example, you can use code from this quest
item

Hallate's Maid Reagent Pouch opens into:

  • 2x etc_reagent_silver_i00.png Quicksilver 30%
    2x etc_broken_crystal_silver_i00.png Moonstone Shard 30%
    1x etc_piece_bone_black_i00.png Rotten Bone Piece 20%
    1x etc_inf_ore_least_i00.png Infernium Ore 20%
Okey, thank you for the advice i will try it :p
 
Which source code do you use?
May be some more useful examples you can find inside data pack...
 
Оффтоп:
Какой то странный английский, мне кажется, или кто то пытается выставить себя тем, кем не является?
 
Оффтоп:
Какой то странный английский, мне кажется, или кто то пытается выставить себя тем, кем не является?
Мб какой то француз, или кто-то другой...
Если про меня то я вообще безграмотностный хохол
 
Acis 370 rev.
Interlude.

First you must create the item Surprise Box in server and client sides. It's for server side.
go to data/stats/items/
create 10000-10099.xml
start of file must be <list> in end, the same of start but with ending tag</list>
between <list> and </list> insert this:
Код:
    <item id="10000" type="Item" name="Surprise Box">
        <set name="default_action" val="capsule" />
        <set name="material" val="LIQUID" />
        <set name="weight" val="600" />
        <set name="price" val="0" />
        <set name="is_tradable" val="false"/>
        <set name="is_droppable" val="false"/>
        <set name="handler" val="ItemSkills" />
        <set name="item_skill" val="10000-1" />
    </item>

Second add the skill whose will invoked by the item.
find data/stats/skill/
create in folder the new file with .xml direction
for example: 10000-10099.xml
and insert this code to your created .xml
Код:
<skill id="10000" levels="1" name="Surprise Box">
        <table name="#extractableItems">
        <!-- 4037 - item id, 50 - item count, 100 - chance of drop when you extract the item
                in this example i put items
                COL, 50 units, 100% chance
                ADENA, 1kk, with 50% chance
                ENRIA, 1 unit, with 20% chance
        -->
            4037,50,100;
            57,1000000,50;
            4042,450,20
        </table>
        <set name="capsuled_items_skill" val="#extractableItems"/>
        <set name="mpConsume" val="366"/>
        <set name="target" val="TARGET_SELF"/>
        <set name="hitTime" val="3000"/>
        <set name="skillType" val="EXTRACTABLE"/>
        <set name="operateType" val="OP_ACTIVE"/>
        <set name="isMagic" val="true"/>
        <set name="itemConsumeId" val="1461"/>
        <set name="itemConsumeCount" val="1"/>
        <set name="reuseDelay" val="180000"/>
    </skill>

@Notice
You must create the item in client side, or your item will not be usable.

@See
Java code of realisation for Skill, you can find in tQfL8V83RZadAvraS3hF0w.png
Java code of realisation for Item, you can find in HgO-vqDpSDyTwYNqUUd28Q.png

Good Luck dude.
 
Acis 370 rev.
Interlude.

First you must create the item Surprise Box in server and client sides. It's for server side.
go to data/stats/items/
create 10000-10099.xml
start of file must be <list> in end, the same of start but with ending tag</list>
between <list> and </list> insert this:
Код:
    <item id="10000" type="Item" name="Surprise Box">
        <set name="default_action" val="capsule" />
        <set name="material" val="LIQUID" />
        <set name="weight" val="600" />
        <set name="price" val="0" />
        <set name="is_tradable" val="false"/>
        <set name="is_droppable" val="false"/>
        <set name="handler" val="ItemSkills" />
        <set name="item_skill" val="10000-1" />
    </item>

Second add the skill whose will invoked by the item.
find data/stats/skill/
create in folder the new file with .xml direction
for example: 10000-10099.xml
and insert this code to your created .xml
Код:
<skill id="10000" levels="1" name="Surprise Box">
        <table name="#extractableItems">
        <!-- 4037 - item id, 50 - item count, 100 - chance of drop when you extract the item
                in this example i put items
                COL, 50 units, 100% chance
                ADENA, 1kk, with 50% chance
                ENRIA, 1 unit, with 20% chance
        -->
            4037,50,100;
            57,1000000,50;
            4042,450,20
        </table>
        <set name="capsuled_items_skill" val="#extractableItems"/>
        <set name="mpConsume" val="366"/>
        <set name="target" val="TARGET_SELF"/>
        <set name="hitTime" val="3000"/>
        <set name="skillType" val="EXTRACTABLE"/>
        <set name="operateType" val="OP_ACTIVE"/>
        <set name="isMagic" val="true"/>
        <set name="itemConsumeId" val="1461"/>
        <set name="itemConsumeCount" val="1"/>
        <set name="reuseDelay" val="180000"/>
    </skill>

@Notice
You must create the item in client side, or your item will not be usable.

@See
Java code of realisation for Skill, you can find in tQfL8V83RZadAvraS3hF0w.png
Java code of realisation for Item, you can find in HgO-vqDpSDyTwYNqUUd28Q.png

Good Luck dude.
Thank you for this answer buddy!
 
Im getting this when i try to use the item. "the number of items is incorrect." Any suggestions?
P.S. - I was had no time to test earlier.
 
Назад
Сверху Снизу