這個是一套簡單的傳送寶石的腳本,只實現簡單的傳送。主要是方便初學者參考使用! 1、在魔獸世界私服單機中,可能會用到使用某單獨一個物品就實現傳送 2、傳送地址在腳本中控制,如果你需要修改傳送位置,你需要修改一下代碼中的 player->TeleportTo(0, 1234.00f, 4321.00f, 1242.00f, 4323.00f); // 這里就是你想要傳送的位置 3、傳送坐標,這個你需要自己到WOW單機游戲中去定位 定位坐標的方法:.gps 命令 4、這個腳本適用於TrinityCore最新版本 5、使用這個腳本,你需要先學會如何在TrinityCore 中增加C++腳本 代碼如下: /* Made by: aaddss A.K.A Deathsoul untested (in game) */ #include "ScriptPCH.h" class item_teleport : public ItemScript { public: item_teleport() : ItemScript("item_teleport") {} bool Onuse(Player * player, Item * /*item*/, SpellCastTargets const& /*targets*/) { if (player->isInCombat()) { player->GetSession()->SendNotification(" You are in combat!"); } { player->TeleportTo(0, 1234.00f, 4321.00f, 1242.00f, 4323.00f); // please change the map id , x , z , y , o (or it will not teleport where u want return true; } } }; void AddSC_item_teleport() { new item_teleport(); } 這個腳本比較簡單。比較適合Trinity端的初學者。喜歡研究T端魔獸世界單機的朋友,可以試試。。
