Topic hỏi đáp (tập 5) về cách làm map

Status
Không mở trả lời sau này.
Hướng dẫn làm cái thằng xa phu giống như Kiếm Thế của Rex đc kô
Cái đó mò mãi kô hiểu
 
sao không chĩu mài mò
có sẵn bản kiemthe1.0 chưa protect mà
 
1. tăng/giảm attack range như vậy là không thể, sử dụng 2 upgrade (1 tăng, 1 giảm) thì có khả năng nhưng cũng có giới hạn. Về move speed thì mỗi item cho một ability Item Move Speed Bonus có giá trị âm.

Mình tưởng Item Move Speed Bonus ko stack với nhau, vì cầm 2 cái giày thì đâu có chạy nhanh hơn được? Và giả sử khi cầm 1 item -ms, 1 item +ms thì nó có tính ms = cả 2 item ko hay chỉ tính 1 cái?
-------------
Cho hỏi nữa là trigger này có vấn đề gì ko mà ko thấy nó deal dam vào group UnitLife?

Mã:
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to War Stomp
    Actions
        Set Mui[26] = (Mui[26] + 1)
        Set Tanker[Mui[26]] = (Triggering unit)
        Set Point[Mui[26]] = (Position of Tanker[Mui[26]])
        Set UnitDie[Mui[26]] = (Units within 300.00 of Point[Mui[26]] matching ((((Matching unit) is dead) Equal to True) and (((Matching unit) is A structure) Equal to False)))
        Set NumberDieunit[Mui[26]] = (Number of units in UnitDie[Mui[26]])
        Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
        Unit Group - Pick every unit in UnitDie[Mui[26]] and do (Actions)
            Loop - Actions
                Set Point[Mui[26]] = (Position of (Picked unit))
                Special Effect - Create a special effect at Point[Mui[26]] using Objects\Spawnmodels\Orc\OrcLargeDeathExplode\OrcLargeDeathExplode.mdl
                Special Effect - Destroy (Last created special effect)
                Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
                Unit - Remove (Picked unit) from the game
        Set Point[Mui[26]] = (Position of Tanker[Mui[26]])
        Set UnitLife[Mui[26]] = (Units within 300.00 of Point[Mui[26]] matching (((((Matching unit) belongs to an enemy of (Owner of Tanker[Mui[26]])) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) is Magic Immune) Equal to False))) and ((((Matching uni
        Unit Group - Pick every unit in UnitLife[Mui[26]] and do (Actions)
            Loop - Actions
                Unit - Cause Tanker[Mui[26]] to damage (Picked unit), dealing ((10.00 x (Real((Level of War Stomp for Tanker[26])))) x (Real(NumberDieunit[Mui[26]]))) damage of attack type Spells and damage type Normal
        Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
        Custom script:   call DestroyGroup(udg_UnitDie[udg_Mui[26]])
        Custom script:   call DestroyGroup(udg_UnitLife[udg_Mui[26]])
 
Tom ơi, có thể ghép 2 jass (đoạn jass ngắn, liên kết với nhau) chung 1 trigger k vậy :)
 
YAN[asian];15783037 nói:
Mình tưởng Item Move Speed Bonus ko stack với nhau, vì cầm 2 cái giày thì đâu có chạy nhanh hơn được? Và giả sử khi cầm 1 item -ms, 1 item +ms thì nó có tính ms = cả 2 item ko hay chỉ tính 1 cái?
-------------
Cho hỏi nữa là trigger này có vấn đề gì ko mà ko thấy nó deal dam vào group UnitLife?

Mã:
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to War Stomp
    Actions
        Set Mui[26] = (Mui[26] + 1)
        Set Tanker[Mui[26]] = (Triggering unit)
        Set Point[Mui[26]] = (Position of Tanker[Mui[26]])
        Set UnitDie[Mui[26]] = (Units within 300.00 of Point[Mui[26]] matching ((((Matching unit) is dead) Equal to True) and (((Matching unit) is A structure) Equal to False)))
        Set NumberDieunit[Mui[26]] = (Number of units in UnitDie[Mui[26]])
        Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
        Unit Group - Pick every unit in UnitDie[Mui[26]] and do (Actions)
            Loop - Actions
                Set Point[Mui[26]] = (Position of (Picked unit))
                Special Effect - Create a special effect at Point[Mui[26]] using Objects\Spawnmodels\Orc\OrcLargeDeathExplode\OrcLargeDeathExplode.mdl
                Special Effect - Destroy (Last created special effect)
                Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
                Unit - Remove (Picked unit) from the game
        Set Point[Mui[26]] = (Position of Tanker[Mui[26]])
        Set UnitLife[Mui[26]] = (Units within 300.00 of Point[Mui[26]] matching (((((Matching unit) belongs to an enemy of (Owner of Tanker[Mui[26]])) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) is Magic Immune) Equal to False))) and ((((Matching uni
        Unit Group - Pick every unit in UnitLife[Mui[26]] and do (Actions)
            Loop - Actions
                Unit - Cause Tanker[Mui[26]] to damage (Picked unit), dealing ((10.00 x (Real((Level of War Stomp for Tanker[26])))) x (Real(NumberDieunit[Mui[26]]))) damage of attack type Spells and damage type Normal
        Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
        Custom script:   call DestroyGroup(udg_UnitDie[udg_Mui[26]])
        Custom script:   call DestroyGroup(udg_UnitLife[udg_Mui[26]])

bạn này, bạn pick 2 lần group để làm gì? thì đương nhiên là ko được nếu pick thì chỉ 1 lần thôi, làm như bạn thì đương nhiên là ko deal đc damage. lần pick thứ 2 của bạn ko có tác dụng, ở lần 1 phải deal damage luôn và bạn nên cho thêm là matching unit is magic immune equal to false( vì bạn deal damage magic và normal nên sẽ chỉ được 1/2 damage vào con chống phép).
 
Lần pick thứ nhất là để mình check số unit đã chết để deal dam vào những unit còn sống dựa vào số unit đã chết đó. Nếu chỉ set 1 group thì đếm số unit chết kiểu gì nhỉ?
 
Làm thế nào để play một music cho
Mã:
Player - Player 2 (Blue) types a chat message containing -music 1 as An exact match
mà Player khác không nghe dc ?
 
Mã:
Unit - Remove (Picked unit) from the game
đã remove hết rồi thì lấy đâu ra số lượng unit mà gây damage
Khắc phục tốt nhất là:
Mã:
        Set Mui[26] = (Mui[26] + 1)
        Set Tanker[Mui[26]] = (Triggering unit)
        Set Point[Mui[26]] = (Position of Tanker[Mui[26]])
        Set UnitDie[Mui[26]] = (Units within 300.00 of Point[Mui[26]] matching ((((Matching unit) is dead) Equal to True) and (((Matching unit) is A structure) Equal to False)))
        Set NumberDieunit[Mui[26]] = (Number of units in UnitDie[Mui[26]])
        Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
        Set Point[Mui[26]] = (Position of Tanker[Mui[26]])
        Set UnitLife[Mui[26]] = (Units within 300.00 of Point[Mui[26]] matching (((((Matching unit) belongs to an enemy of (Owner of Tanker[Mui[26]])) Equal to True) and ((((Matching unit) is alive) Equal to True) and (((Matching unit) is Magic Immune) Equal to False))) and ((((Matching uni
        Unit Group - Pick every unit in UnitLife[Mui[26]] and do (Actions)
            Loop - Actions
                Unit - Cause Tanker[Mui[26]] to damage (Picked unit), dealing ((10.00 x (Real((Level of War Stomp for Tanker[26])))) x (Real(NumberDieunit[Mui[26]]))) damage of attack type Spells and damage type Normal
        Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
	Unit Group - Pick every unit in UnitDie[Mui[26]] and do (Actions)
            Loop - Actions
                Set Point[Mui[26]] = (Position of (Picked unit))
                Special Effect - Create a special effect at Point[Mui[26]] using Objects\Spawnmodels\Orc\OrcLargeDeathExplode\OrcLargeDeathExplode.mdl
                Special Effect - Destroy (Last created special effect)
                Custom script:   call RemoveLocation(udg_Point[udg_Mui[26]])
                Unit - Remove (Picked unit) from the game
        Custom script:   call DestroyGroup(udg_UnitDie[udg_Mui[26]])
        Custom script:   call DestroyGroup(udg_UnitLife[udg_Mui[26]])
Mà xài 1 Point[...] lập đi lặp lại nhiều lần = 1 số 26 thì dễ gây lỗi lắm đó:|
 
Cho hỏi cách làm 1 skill Jass đơn giản. Nếu convert từ GUI -> Jass thì ko có cái Local Var. Cho hỏi luôn Local Var và Gobal Var khác nhau thế nào ?? Cái nào để làm MUI ???
P/s: Nếu muốn làm Damage Spell = damage base của hero thì có phải dùng lệnh GetUserData() ko ???
Post thứ 3 vẫn chưa ai trả lời
 
ai rãnh làm giúp mình 1 trigger khi giết 1 con lính rớt item random trigger nhá không có lính ở sẵn trên bản đồ :D
 
ai rãnh làm giúp mình 1 trigger khi giết 1 con lính rớt item random trigger nhá không có lính ở sẵn trên bản đồ :D

dễ mà
Nếu cần thì thêm điều kiện cho unit die
 
Chỉnh sửa cuối:
Post thứ 3 vẫn chưa ai trả lời

Làm spell Jass đơn giản thì bạn đọc bài GUI to Jass của anh Tom đi.

Local var thì là 1 biến chỉ dùng đc trong 1 function duy nhất và cái này dùng để làm MUI, còn global var thì nó cũng giống như var bình thường ở GUI.
 
cái đó giống random hero vậy mà không nghĩ ra

random hero
Events
Player - Player 1 (Red) types a chat message containing -random as An exact match
Conditions
Actions
Set random = (Random integer number between 1 and 3)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
random Equal to 1
Then - Actions
Unit - Create 1 Paladin for Player 1 (Red) at (Center of Region 018 <gen>) facing Default building facing degrees
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
random Equal to 2
Then - Actions
Unit - Create 1 Archmage for Player 1 (Red) at (Center of Region 018 <gen>) facing Default building facing degrees
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
random Equal to 3
Then - Actions
Unit - Create 1 Bóa Lïn for Player 1 (Red) at (Center of Region 018 <gen>) facing Default building facing degrees
Else - Actions
Do nothing
Trigger - Turn off (This trigger)
cái này ai thêm giúp mình làm sao để khi người chơi khác chơi mới random mới ra
 
thì chỉnh ko phải là com hay player thì remove hết unit trên bản đồ
 
các bác cho e hỏi làm sao để đánh chết 1 con woai làm rơi ra cái đồng tiền vàng với tỉ lệ là 50%
E thử làm bằng cách kích vào từng con rồi chọn item drop nhưng sau khi quái hồi sinh thì đánh kô rơi ra cái j nữa
Ag e hồi sinh quái bằng replace unit còn cách nào để hồi sinh quái sau khi bị đập chết kô?
 
các bác cho e hỏi làm sao để đánh chết 1 con woai làm rơi ra cái đồng tiền vàng với tỉ lệ là 50%
E thử làm bằng cách kích vào từng con rồi chọn item drop nhưng sau khi quái hồi sinh thì đánh kô rơi ra cái j nữa
Ag e hồi sinh quái bằng replace unit còn cách nào để hồi sinh quái sau khi bị đập chết kô?
tương tự như này, bộ spam hã ?:|
http://forum.gamevn.com/showthread....tap-5-ve-cach-lam-map&p=15795446#post15795446
ở trên là đánh unit ra item
-------------
còn tỉ lệ ra 50% tiền thì
random = 2
1 = add money
2 = no action
 
Chỉnh sửa cuối:
tình hình là mình muốn trong map chỉ 1 khu vực có tuyết rơi thì làm thế nào thank :>
 
tạo cái region
enter nó -> [v] weather efect -> thời tiết chọn
 
cái đó giống random hero vậy mà không nghĩ ra

random hero
Events
Player - Player 1 (Red) types a chat message containing -random as An exact match
Conditions
Actions
Set random = (Random integer number between 1 and 3)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
random Equal to 1
Then - Actions
Unit - Create 1 Paladin for Player 1 (Red) at (Center of Region 018 <gen>) facing Default building facing degrees
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
random Equal to 2
Then - Actions
Unit - Create 1 Archmage for Player 1 (Red) at (Center of Region 018 <gen>) facing Default building facing degrees
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
random Equal to 3
Then - Actions
Unit - Create 1 Bóa Lïn for Player 1 (Red) at (Center of Region 018 <gen>) facing Default building facing degrees
Else - Actions
Do nothing
Trigger - Turn off (This trigger)
cái này ai thêm giúp mình làm sao để khi người chơi khác chơi mới random mới ra

random kiểu này hok có hiệu quả tốt :|

tốt nhất theo kiểu sele hero của anh tom á
rất là hiệu quả
đầu tiên
tạo một region trong phạm vị nó
rùi để hero cần random vào hay sele vào
tiếp theo làm mã của mình như vậy vào
Mã:
Random Model
    Events
        Player - Player 2 (Blue) types a chat message containing -ar as An exact match
        Player - Player 8 (Pink) types a chat message containing -ar as An exact match
    Conditions
    Actions
        Cinematic - Clear the screen of text messages for (All players)
        Quest - Display to (All players) the Quest Failed message: ((Player_Colors[(Player number of (Triggering player))] + (Name of (Triggering player))) +  |rhas selected |c007ebff1All Random|r)
        Player Group - Pick every player in (All players matching (((Matching unit) belongs to an ally of Player 1 (Red)) Equal to True)) and do (Actions)
            Loop - Actions
                Camera - Pan camera for (Picked player) to (Center of Night Elf Sentinel <gen>) over 0.00 seconds
        Player Group - Pick every player in (All players matching (((Matching unit) belongs to an ally of Player 7 (Green)) Equal to True)) and do (Actions)
            Loop - Actions
                Camera - Pan camera for (Picked player) to (Center of Undead Scourge <gen>) over 0.00 seconds
        Trigger - Turn off Model Initialization Set <gen>
        Trigger - Turn off HeroSelect Init <gen>
        Trigger - Turn off Normal Model <gen>
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 2 (Blue) controller) Not equal to Computer
                (Player 2 (Blue) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Night Elf <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 2 (Blue) at (Center of Player 2 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.01 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 3 (Teal) controller) Not equal to Computer
                (Player 3 (Teal) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Night Elf <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 3 (Teal) at (Center of Player 3 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.02 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 4 (Purple) controller) Not equal to Computer
                (Player 4 (Purple) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Night Elf <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 4 (Purple) at (Center of Player 4 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.03 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 5 (Yellow) controller) Not equal to Computer
                (Player 5 (Yellow) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Night Elf <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 5 (Yellow) at (Center of Player 5 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.04 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 6 (Orange) controller) Not equal to Computer
                (Player 6 (Orange) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Night Elf <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 6 (Orange) at (Center of Player 6 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.05 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 8 (Pink) controller) Not equal to Computer
                (Player 8 (Pink) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Undead <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 8 (Pink) at (Center of Player 8 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.06 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 9 (Gray) controller) Not equal to Computer
                (Player 9 (Gray) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Undead <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 9 (Gray) at (Center of Player 9 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.07 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 10 (Light Blue) controller) Not equal to Computer
                (Player 10 (Light Blue) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Undead <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 10 (Light Blue) at (Center of Player 10 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.08 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 11 (Dark Green) controller) Not equal to Computer
                (Player 11 (Dark Green) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Undead <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 11 (Dark Green) at (Center of Player 11 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Wait 0.09 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Player 12 (Brown) controller) Not equal to Computer
                (Player 12 (Brown) slot status) Equal to Is playing
            Then - Actions
                Unit Group - Pick every unit in (Random 1 units from (Units in Undead <gen>)) and do (Actions)
                    Loop - Actions
                        Unit - Remove (Picked unit) from the game
                        Unit - Create 1 (Unit-type of (Picked unit)) for Player 12 (Brown) at (Center of Player 12 <gen>) facing 270.00 degrees
                        Selection - Select (Last created unit) for (Triggering player)
                        Game - Display to (All players matching ((Owner of (Last created unit)) Not equal to (Owner of (Last created unit)))) the text: (Player_Colors[(Player number of (Owner of (Last created unit)))] + ((  + (Name of (Owner of (Last created unit)))) + ( |rhas random  + ((Proper name of (Last created unit)) + 's.))))
            Else - Actions
        Trigger - Turn off (This trigger)
xin lổi mình chỉ giúp đến đây thui vì lý do hok có nhiều thời gian lắm
mong bạn hiểu cho :D


Nhớ rằng đừng bao h cho chế độ wait vào tại vì wait có thể làm cho lổi
do ở đây hok có đặt giá trị vì vậy lát created unit có thể bị nhầm


ai rãnh làm giúp mình 1 trigger khi giết 1 con lính rớt item random trigger nhá không có lính ở sẵn trên bản đồ :D

câu này quá dơn giản bạn chỉ cần

Mã:
[COLOR="Blue"]TheTest
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Set OOOOOOOOO[1] = Claws of Attack +12
        Set OOOOOOOOO[2] = Cloak of Shadows
        Item - Create OOOOOOOOO[(Random integer number between 1 and 2)] at (Position of (Dying unit))
[/COLOR]

hay nhớ rằng
OOOOOOOOO là giá trị của item

bạn có thể chọn giá trị như sau
Mã:
[COLOR="Lime"]OOOOOOOOO
Item-Type
Array Size 1[/COLOR]
Item - Create OOOOOOOOO[(Random integer number between 1 and 2)] at (Position of (Dying unit))
từ 1 and 2 là theo thứ tự của đầu giá trị set cho

Mã:
[COLOR="Blue"]TheTest
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Set OOOOOOOOO[1] = Claws of Attack +12
        Set OOOOOOOOO[2] = Cloak of Shadows
        Set OOOOOOOOO[3] = Claws of Attack +15
        Item - Create OOOOOOOOO[(Random integer number between 1 and 3)] at (Position of (Dying unit))
[/COLOR]
nếu có một giá trị set thì bạn set cho 1 and 3 nha
cái này mà nhầm mình hok giám chắc là random dc :-ss

chúc bạn may mắn :)
 

Attachments

Last edited by a moderator:
có ai bít sử dụng egui set damg hero = damg unit k? (hoặc ngược lại)
------------
ai bit trã lời dùm :D
 
Chỉnh sửa cuối:
Status
Không mở trả lời sau này.
Back
Top