YTDB

Вернуться   YTDB > Баг-репорты (Патчи) / Bug reports (Patches) 4.3.4 > Необходима поддержка скриптов / Needs script support

Необходима поддержка скриптов / Needs script support Все сделать через базу невозможно.

Данный раздел специально выделен для скриптов, реализующих действия, которые невозможно реализовать через базу.

Ответ
 
Опции темы Поиск в этой теме Опции просмотра
Старый 13.02.2015, 11:52   #1
Ulduar
Ученый
 
Регистрация: 23.11.2012
Сообщений: 196
Сказал(а) спасибо: 69
Поблагодарили 16 раз(а) в 16 сообщениях
Ulduar На верном пути
По умолчанию Стартовый ICC эвент.

Стартовая болтовня после убийства двух Проклятых.
Копирайты Boxa проставлены не случайно, я его реализацию из R2 брал.
Код:
-- ###########
-- ICC start speech event. https://github.com/boxa copyright, /* Copyright (C) 2015 by boxa for ScriptDev2_R2 <http://github.com/mangosR2/scriptdev2/> This is his rightful authorship. Nobody has the rights to delete them. Nobody ever.
-- ###########

-- db text
SET @DB_STRING_ENTRY:=2000010000;
DELETE FROM db_script_string WHERE entry BETWEEN @DB_STRING_ENTRY AND @DB_STRING_ENTRY+18;
INSERT INTO db_script_string (entry,content_default,sound,type,language,emote,comment) VALUES
(@DB_STRING_ENTRY+0,'This is our final stand. What happens here will echo through the ages. Regardless of outcome, they will know that we fought with honor. That we fought for the freedom and safety of our people!',16653,6,0,22,'Highlord Tirion Fordring - SAY_TIRION_INTRO_1'),
(@DB_STRING_ENTRY+1,'Remember, heroes, fear is your greatest enemy in these befouled halls. Steel your heart and your soul will shine brighter than a thousand suns. The enemy will falter at the sight of you. They will fall as the light of righteousness envelops them!',16654,6,0,22,'Highlord Tirion Fordring - SAY_TIRION_INTRO_2'),
(@DB_STRING_ENTRY+2,'Our march upon Icecrown Citadel begins now!',16655,6,0,22,'Highlord Tirion Fordring - SAY_TIRION_INTRO_3'),
(@DB_STRING_ENTRY+3,'ARTHAS! I swore that I would see you dead and the Scourge dismantled! I''m going to finish what I started at Light''s Hope!',16656,6,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_4'),
(@DB_STRING_ENTRY+4,'The power of the Light knows no bounds, Saurfang. His soul is under great strain, but he lives - for now.',16658,6,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_H_5'),
(@DB_STRING_ENTRY+5,'By the Light, it must be so!',16657,6,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_A_5'),
-- The Lich King
(@DB_STRING_ENTRY+6,'You now stand upon the hallowed ground of the Scourge. The Light won''t protect you here, paladin. Nothing will protect you...',17230,6,0,0,'The Lich King - SAY_LK_INTRO_1'),
(@DB_STRING_ENTRY+7,'You could have been my greatest champion, Fordring: A force of darkness that would wash over this world and deliver it into a new age of strife.',17231,6,0,0,'The Lich King - SAY_LK_INTRO_2'),
(@DB_STRING_ENTRY+8,'But that honor is no longer yours. Soon,I will have a new champion.',17232,6,0,0,'The Lich King - SAY_LK_INTRO_3'),
(@DB_STRING_ENTRY+9,'The breaking of this one has been taxing. The atrocities I have committed upon his soul. He has resisted for so long, but he will bow down before his king soon.',17233,6,0,0,'The Lich King - SAY_LK_INTRO_4'),
(@DB_STRING_ENTRY+10,'In the end, you will all serve me.',17234,6,0,0,'The Lich King - SAY_LK_INTRO_5'),
-- Highlord Bolvar Fordragon
(@DB_STRING_ENTRY+11,'NEVER! I... I will never... serve... you...',17078,6,0,0,'Highlord Bolvar Fordragon - SAY_BOLVAR_INTRO_1'),
-- High Overlord Saurfang
(@DB_STRING_ENTRY+12,'The paladin still lives? Is it possible, Highlord? Could he have survived?',17107,6,0,0,'High Overlord Saurfang - SAY_SAURFANG_INTRO_1'),
(@DB_STRING_ENTRY+13,'Then we must save him! If we rescue Bolvar Fordragon, we may quell the unrest between the Alliance and the Horde.',17108,6,0,0,'High Overlord Saurfang - SAY_SAURFANG_INTRO_2'),
(@DB_STRING_ENTRY+14,'Our mission is now clear: The Lich King will answer for his crimes and we will save Highlord Bolvar Fordragon!',17109,6,0,0,'High Overlord Saurfang - SAY_SAURFANG_INTRO_3'),
(@DB_STRING_ENTRY+15,'Kor''kron, prepare Orgrim''s Hammer for its final voyage! Champions, our gunship will find a point to dock on the upper reaches of the citadel. Meet us there!',17110,6,0,0,'High Overlord Saurfang - SAY_SAURFANG_INTRO_1'),
-- Muradin Bronzebeard
(@DB_STRING_ENTRY+16,'Could it be, Lord Fordring? If Bolvar lives, mayhap there is hope fer peace between the Alliance and the Horde. We must reach the top o'' this cursed place and free the paladin!',16980,6,0,0,'Muradin Bronzebeard - SAY_MURADIN_INTRO_1'),
(@DB_STRING_ENTRY+17,'Prepare the Skybreaker fer an aerial assault on the citadel!',16981,6,0,0,'Muradin Bronzebeard - SAY_MURADIN_INTRO_2'),
(@DB_STRING_ENTRY+18,'Heroes, ye must fight yer way to a clear extraction point within Icecrown. We''ll try an'' rendezvous on the ramparts!',16982,6,0,0,'Muradin Bronzebeard - SAY_MURADIN_INTRO_3');





-- Script id: 37011
DELETE FROM dbscripts_on_creature_death WHERE id=37011;
INSERT INTO dbscripts_on_creature_death VALUES 
(37011,0,35,5,500,0,0,0,0,0,0,0,0,0,0,0,'Damned - on death - Send AI Event Custom A(inform Tirion about start event)'),
(37011,0,31,37011,15,0,0,8,0,0,0,0,0,0,0,0,'Return true script, if found alive Damned(need two Damned kills for start speech event)');




-- creature movement for Highlord Tirion Fordring, High Overlord Saurfang and Muradin.
DELETE FROM creature_movement_template WHERE entry IN (37119, 37187, 37200);
INSERT INTO creature_movement_template (entry,point,position_x,position_y,position_z,waittime,script_id,orientation) VALUES
(37119, 1, -48.9184, 2213.55, 27.9859, 1000, 3711901, 3.12865),
(37187, 1, -48.9097, 2211.06, 27.9859, 1000, 3718701, 3.15905),
(37200, 1, -48.8073, 2211.06, 27.9859, 1000, 3720001, 3.14159); 

-- Script id: 3711901
DELETE FROM dbscripts_on_creature_movement WHERE id IN (3711901, 3718701, 3720001);
INSERT INTO dbscripts_on_creature_movement VALUES 
(3711901,0,0,6,0,0,0,0,@DB_STRING_ENTRY+0,0,0,0,0,0,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_1'),
(3711901,13,0,6,0,0,0,0,@DB_STRING_ENTRY+1,0,0,0,0,0,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_2'),
(3711901,29,0,6,0,0,0,0,@DB_STRING_ENTRY+2,0,0,0,0,0,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_3'),
(3711901,35,0,6,0,37181,50000,0,@DB_STRING_ENTRY+6,0,0,0,0,0,0,0,'Lich King - SAY_INTRO_1.'),
(3711901,49,0,6,0,0,0,0,@DB_STRING_ENTRY+3,0,0,0,0,0,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_4'),
(3711901,58,0,6,0,37181,50000,0,@DB_STRING_ENTRY+7,0,0,0,0,0,0,0,'Lich King - SAY_INTRO_2.'),
(3711901,71,0,6,0,37181,50000,0,@DB_STRING_ENTRY+8,0,0,0,0,0,0,0,'Lich King - SAY_INTRO_3'),
(3711901,81,0,6,0,37181,50000,0,@DB_STRING_ENTRY+9,0,0,0,0,0,0,0,'Lich King - SAY_INTRO_4'),
(3711901,103,0,6,0,37181,50000,0,@DB_STRING_ENTRY+10,0,0,0,0,0,0,0,'Lich King - SAY_INTRO_5'),
(3711901,108,0,6,0,37183,50000,0,@DB_STRING_ENTRY+11,0,0,0,0,0,0,0,'Highlord Bolvar Fordragon - SAY_INTRO_1.'),
(3711901,0,32,1,0,0,0,0,0,0,0,0,0,0,0,0,'Highlord Tirion Fordring - Pause Movement.'),
(3711901,114,35,5,20,0,0,0,0,0,0,0,0,0,0,0,'High Tirion Fordring - Send AI Event Custom A for High Overlord Saurfang.'),
(3711901,114,35,5,20,0,0,0,0,0,0,0,0,0,0,0,'High Tirion Fordring - Send AI Event Custom A for Muradin Bronzebeard.'),
(3718701,0,32,1,0,0,0,0,0,0,0,0,0,0,0,0,'High Overlord Saurfang - Pause Movement'),
(3718701,0,0,6,0,0,0,0,@DB_STRING_ENTRY+12,0,0,0,0,0,0,0,'High Overlord Saurfang - SAY_INTRO_1'),
(3718701,6,0,0,0,37119,20,0,@DB_STRING_ENTRY+4,0,0,0,0,0,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_H_5'),
(3718701,14,0,6,0,0,0,0,@DB_STRING_ENTRY+13,0,0,0,0,0,0,0,'High Overlord Saurfang - SAY_INTRO_2.'),
(3718701,24,0,6,0,0,0,0,@DB_STRING_ENTRY+14,0,0,0,0,0,0,0,'High Overlord Saurfang - SAY_INTRO_3'),
(3718701,33,0,6,0,0,0,0,@DB_STRING_ENTRY+15,0,0,0,0,0,0,0,'High Overlord Saurfang - SAY_INTRO_4'),
(3718701,44,18,1000,0,0,0,0,0,0,0,0,0,0,0,0,'High Overlord Saurfang - Force Despawn.'),
(3720001,0,32,1,0,0,0,0,0,0,0,0,0,0,0,0,'Muradin Bronzebeard - Pause Movement'),
(3720001,0,0,6,0,0,0,0,@DB_STRING_ENTRY+16,0,0,0,0,0,0,0,'Muradin Bronzebeard - SAY_INTRO_1'),
(3720001,12,0,0,0,37119,20,0,@DB_STRING_ENTRY+5,0,0,0,0,0,0,0,'Highlord Tirion Fordring - SAY_TIRION_INTRO_A_5'),
(3720001,15,0,6,0,0,0,0,@DB_STRING_ENTRY+17,0,0,0,0,0,0,0,'Muradin Bronzebeard - SAY_INTRO_2.'),
(3720001,19,0,6,0,0,0,0,@DB_STRING_ENTRY+18,0,0,0,0,0,0,0,'Muradin Bronzebeard - SAY_INTRO_3'),
(3720001,27,18,1000,0,0,0,0,0,0,0,0,0,0,0,0,'Muradin Bronzebeard - Force Despawn.');


-- if need, settlment npc reference intro speech event for ICC. Thanks YTDB for data.
REPLACE INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `currentwaypoint`, `curhealth`, `curmana`, `DeathState`, `MovementType`) VALUES
('136291','37119','631','15','1','0','0','-48.9184','2213.55','27.9859','3.12865','604800','0','0','13945000','8516000','0','0'),
('79239','37181','631','15','1','0','0','-123.964','2211.56','82.6835','1.0472','604800','0','0','27890000','17032000','0','0'),
('49035','37183','631','15','1','0','0','-126.295','2211.68','82.2289','0','604800','0','0','630000','159760','0','0'),
('136293','37187','631','15','64','0','0','-48.9097','2211.06','27.9859','3.15905','604800','0','0','4183500','0','0','0'),
('373430','37200','631','15','1','0','0','-48.8073','2211.06','27.9859','3.14159','604800','0','0','4183500','0','0','0');

-- Creature id: 37200
UPDATE creature_template SET AIName='EventAI' WHERE entry=37200;
DELETE FROM creature_ai_scripts WHERE creature_id=37200;
INSERT INTO creature_ai_scripts VALUES 
('3720001','37200','30','0','100','30','5','37119','0','0','48','2','0','0','0','0','0','0','0','0','0','0','Muradin Bronzebeard - Change Movement on Waypoint Motion Type on Receive AI Event Custom A from Highlord Tirion Fordring.');

-- Creature id: 37187
UPDATE creature_template SET AIName='EventAI' WHERE entry=37187;
DELETE FROM creature_ai_scripts WHERE creature_id=37187;
INSERT INTO creature_ai_scripts VALUES 
('3718701','37187','30','0','100','30','5','37119','0','0','0','0','0','0','0','0','0','0','0','0','0','0','High Overlord Saurfang - Change Movement on Waypoint on Receive AI Event Custom A(pSender == Highlord Tirion Fordring)');

-- Creature id: 37119
UPDATE creature_template SET AIName='EventAI' WHERE entry=37119;
DELETE FROM creature_ai_scripts WHERE creature_id=37119;
INSERT INTO creature_ai_scripts VALUES 
('3711901','37119','11','0','100','30','0','0','0','0','22','1','0','0','0','0','0','0','0','0','0','0','Highlord Tirion Fordring - Set Phase 1 on Spawn(need, because avoid repeat)'),
('3711902','37119','30','1','100','30','5','37011','0','0','22','0','0','0','48','2','0','0','0','0','0','0','Highlord Tirion Fordring - Receive AI Event Custom A(pSender == 37011) - Set Phase 0 and Change Movement - Start Intro Speech Event trigger.');
__________________
Ты кто? Зёбра! Ктооооооо?!
Ulduar вне форума   Ответить с цитированием
Старый 13.02.2015, 11:58   #2
Ulduar
Ученый
 
Регистрация: 23.11.2012
Сообщений: 196
Сказал(а) спасибо: 69
Поблагодарили 16 раз(а) в 16 сообщениях
Ulduar На верном пути
По умолчанию

https://github.com/mangosR2/scriptde...bd62dc65894972
Ссылка, откуда было взято(благодарю автора)
SET @DB_STRING_ENTRY:=2000010000;

Можете легко заменить на нужную вам цифру.
http://ru.wowhead.com/npc=37119
Тирион
http://ru.wowhead.com/npc=37011
Проклятый.
http://ru.wowhead.com/npc=37187
Саурфанг.
http://ru.wowhead.com/npc=37200
Мурадин.
В SD2 трекере(на гит) тоже было выложено, поэтому гуиды тут тоже стоят этих нпц.
__________________
Ты кто? Зёбра! Ктооооооо?!
Ulduar вне форума   Ответить с цитированием
Ответ


Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.



Текущее время: 19:31. Часовой пояс GMT +4.


YTDB - MaNGOS DataBase

Русский форум Мангос - официальный форум RMDC

Главная цель проекта MaNGOS - обучающая, поэтому разрешается использовать исходный код и собранную программу только для образовательных целей.
Вы не можете использовать MaNGOS в коммерческих целях, а также не разрешается устанавливать публичные серверы на базе MaNGOS.
Любое копирование материалов, информации в любом виде без указания источника - форума YTDB будет считаться нарушением авторских прав и нарушением Уголовного Кодекса РФ, ст. 146 ст. 147.
Перевод vBulletin: zCarot
Punk's On-Air - Punk, Folk, Blues, Ska Bascinet - реконструкция denw IL-2 Training Книготорговая Компания «А-5» - художественная, учебная литература, скидки, опт и мелкий опт, доставка, дешево, низкие цены издательства