need help - teleporter npc

12/28/2010 16:59 mangosd#1
hallo,
wie man dem titel ja bereits entnehmen kann, würde ich gerne mal wissen ob jemand weiß wie ich einen funktionierenden teleporter npc erstelle (kein tele-npc mit quest sondern ein gossip-npc).

ich habe die sufu benutzt und auch gegoogelt allerdings ohne richtige ergebnisse... ich weiß bereits das ich dafür eine .lua auf meinem root haben muss.

und falls die infos benötigt werden: linux root, trinity core

mfg,
Dark-Core WoW Projektleiter/Flo aka mangosd


[sorry falls doppelpost, einmal ist der thread erstellt worden, wird aber nichtangezeit, wenn doch einfach einen der beiden beiträge löschen :)]
12/28/2010 17:09 Minoras#2
LUA funzt bei trinity nich^^ man kann Teleporter über DB-Scripts schreiben ^^
Hier mal n kleiner Ausschnitt von meinem :)

Code:
DELETE FROM `creature_template` WHERE `entry`='100001';
INSERT INTO `creature_template` (`entry`,`modelid1`, `name`, `subname`,`gossip_menu_id`, `minlevel`, `maxlevel`,
`faction_A`, `faction_H`, `npcflag`,`rank`, `mindmg`, `maxdmg`,`unit_class`, `unit_flags`, `Health_mod`,
`Mana_mod`,`RegenHealth`, `equipment_id`)
VALUES
('100001', '3167', 'Gesandter aus Acheron', '', '30060', '80', '80', '1078', '1078', '1', '1', '1000000', '2000000', '1', '2', '20', '10', '1', '');
DELETE FROM `gossip_menu_option` WHERE `menu_id`='30060';
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `action_script_id`)
VALUES
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `action_script_id`)
VALUES
('30000', '1', '4', 'Teleports', '1', '1', '30052', '', '');
DELETE FROM `gossip_menu_option` WHERE `menu_id`='30052';
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `action_script_id`)
VALUES
('30052', '1', '4', 'Stormwind', '1', '1', '', '', '20101'),
('30052', '2', '4', 'Eisenschmiede', '1', '1', '', '', '20102'),
('30052', '3', '4', 'Darnassus', '1', '1', '', '', '20103'),
('30052', '4', '4', 'Exodar', '1', '1', '', '', '20104'),
('30052', '5', '4', 'Shattrath', '1', '1', '', '', '20105'),
('30052', '6', '4', 'Dalaran', '1', '1', '', '', '20106');
DELETE FROM `gossip_scripts` WHERE `id` BETWEEN '20101' AND '20107';
INSERT INTO `gossip_scripts` (`id`, `command`, `datalong`, `x`, `y`, `z`, `o`)
VALUES
('20101', '6', '0', '-8910.91', '556.19', '93.64', '0.65'),
('20102', '6', '0', '-5011.86', '-845.86', '497.14', '5.42'),
('20103', '6', '1', '9951.86', '2280.74', '1341.4', '1.59'),
('20104', '6', '530', '-3829.71', '-11693.36', '-106.85', '1.86'),
('20105', '6', '530', '-1690.84', '5369.99', '7.5', '2.78'),
('20106', '6', '571', '5804.81', '615.20', '651.16', '1.64');

DELETE FROM `creature_template` WHERE `entry`='100011';
INSERT INTO `creature_template` (`entry`,`modelid1`, `name`, `subname`,`gossip_menu_id`, `minlevel`, `maxlevel`,
`faction_A`, `faction_H`, `npcflag`,`rank`, `mindmg`, `maxdmg`,`unit_class`, `unit_flags`, `Health_mod`,
`Mana_mod`,`RegenHealth`, `equipment_id`)
VALUES
('100011', '4259', 'Gesandter von Acheron', '', '40052', '80', '80', '85', '85', '1', '1', '1000000', '2000000', '1', '2', '20', '10', '1', '');
DELETE FROM `gossip_menu_option` WHERE `menu_id`='40052';
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `action_script_id`)
VALUES
VALUES
('40052', '1', '4', 'Orgrimmar', '1', '1', '', '', '30101'),
('40052', '2', '4', 'Donnerfels', '1', '1', '', '', '30102'),
('40052', '3', '4', 'Unterstadt', '1', '1', '', '', '30103'),
('40052', '4', '4', 'Silbermond', '1', '1', '', '', '30104'),
('40052', '5', '4', 'Shattrath', '1', '1', '', '', '30105'),
('40052', '6', '4', 'Dalaran', '1', '1', '', '', '30106');
DELETE FROM `gossip_scripts` WHERE `id` BETWEEN '30101' AND '30106';
INSERT INTO `gossip_scripts` (`id`, `command`, `datalong`, `x`, `y`, `z`, `o`)
VALUES
('30101', '6', '1', '1486.84', '-4415.16', '24.09', '0.11'),
('30102', '6', '1', '-1278.72', '127.22', '131.33', '5.22'),
('30103', '6', '0', '1560.98', '240.36', '-43.1', '0.05'),
('30104', '6', '530', '9361.34', '-7277.76', '14.25', '6.22'),
('30105', '6', '530', '-1690.84', '5369.99', '7.5', '2.78'),
('30106', '6', '571', '5804.81', '615.20', '651.16', '1.64');

#######################################
#
# © 2010 by Minoras, Acheron-WoW Team
#
#######################################
EDIT: Den Teleport für Acheron musste rausnehmen wenn du den verwenden willst ^^
12/28/2010 17:16 mangosd#3
sorry das war jetzt mein fehler: also einen normalen teleporternpc haben wir bereits. (ich bin so blöd ^^) was ich meinte war ein teleporter npc der dich zu einzelnen vendoren teleportiert. wir haben unseren server so aufgebaut das man alle 277er items (die gegen ehre zu erhalten sind ^^) und das man dann einfach auf [277er Items] klickt und vor den vendoren steht. also ein rein playertreff-interner teleporter npc :)

sorry nochmal für meine ungenaue beschreibung
12/28/2010 17:30 Minoras#4
Musste einfach nur Teleportnamen und Coords ändern^^
und halt Namen vom NPC und die Texte :P Wenn du mir die Coords gibts kann ich dir des schnell machen^^
12/28/2010 17:31 mangosd#5
öhm okay ich werds versuchen, thx ;)
12/28/2010 17:37 Minoras#6
Ich mach dir den Code mal einfacher^^

Code:
DELETE FROM `creature_template` WHERE `entry`='100011';
INSERT INTO `creature_template` (`entry`,`modelid1`, `name`, `subname`,`gossip_menu_id`, `minlevel`, `maxlevel`,
`faction_A`, `faction_H`, `npcflag`,`rank`, `mindmg`, `maxdmg`,`unit_class`, `unit_flags`, `Health_mod`,
`Mana_mod`,`RegenHealth`, `equipment_id`)
VALUES
('100011', '4259', 'NPC_NAME', '', '40052', '80', '80', '85', '85', '1', '1', '1000000', '2000000', '1', '2', '20', '10', '1', '');
DELETE FROM `gossip_menu_option` WHERE `menu_id`='40052';
INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `action_script_id`)
VALUES
VALUES
('40052', '1', '4', 'teleportname1', '1', '1', '', '', '30101'),
('40052', '2', '4', 'teleportname2', '1', '1', '', '', '30102'),
('40052', '3', '4', 'teleportname3', '1', '1', '', '', '30103'),
('40052', '4', '4', 'teleportname4', '1', '1', '', '', '30104'),
('40052', '5', '4', 'teleportname5', '1', '1', '', '', '30105'),
('40052', '6', '4', 'teleportname6', '1', '1', '', '', '30106');
DELETE FROM `gossip_scripts` WHERE `id` BETWEEN '30101' AND '30106';
INSERT INTO `gossip_scripts` (`id`, `command`, `datalong`, `x`, `y`, `z`, `o`)
VALUES
('30101', '6', 'map', 'x', 'y', 'z', 'O'),  -- teleport1
('30102', '6', 'map', 'x', 'y', 'z', 'O'),  -- teleport2
('30103', '6', 'map', 'x', 'y', 'z', 'O'),  -- teleport3
('30104', '6', 'map', 'x', 'y', 'z', 'O'),  -- teleport4
('30105', '6', 'map', 'x', 'y', 'z', 'O'),  -- teleport5
('30106', '6', 'map', 'x', 'y', 'z', 'O');  -- teleport6
Das letzte findest du alles per .gps command raus^^
Wenn du den NPC für beide Fraktionen verwendest setz oben faction_A und faction_H auf 35