当前位置:首页>>魔兽单机>>正文
服务端:真正的mangos杀人公告源代码
2013-07-05 17:31:01 作者:网络 来源: 浏览次数:0
摘要:魔兽单机版:真正的mangos杀人公告源代码
 Index: src/game/Language.h
 
===================================================================
 
--- src/game/Language.h        (revision 6258)
 
+++ src/game/Language.h        (working copy)
 
@@ -26,6 +26,9 @@
 
     LANG_SELECT_CREATURE                = 2,
 
 
     // level 0 chat
 
+    LANG_YOU_KILLED_NO_SPACE            = 3442,
 
+    LANG_YOU_WERE_KILLED                = 3443,
 
+    LANG_YOU_KILLED                     = 3444,
 
     LANG_SYSTEMMESSAGE                  = 3,
 
     LANG_EVENTMESSAGE                   = 4,
 
     LANG_NO_HELP_CMD                    = 5,
 
Index: src/game/Player.cpp
 
===================================================================
 
--- src/game/Player.cpp        (revision 6258)
 
+++ src/game/Player.cpp        (working copy)
 
@@ -3591,6 +3591,8 @@
 
     setDeathState(CORPSE);
 
     //SetFlag( UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_IN_PVP );
 
 
+    ChatHandler(this).PSendSysMessage(LANG_YOU_WERE_KILLED);
 
+
 
     SetFlag(UNIT_DYNAMIC_FLAGS, 0x00);
 
 
     // 6 minutes until repop at graveyard
 
@@ -5718,7 +5720,28 @@
 
             uint32 k_level = getLevel();
 
             uint32 v_level = pVictim->getLevel();
 
 
+//pvp token start
 
+            uint32 noSpaceForCount = 0;
 
+            uint32 itemId = 29434;
 
+            int32 count = 1;
 
+
 
+            // check space and find places
 
+            ItemPosCountVec dest;
 
+            uint8 msg = CanStoreNewItem( NULL_BAG, NULL_SLOT, dest, itemId, count, &noSpaceForCount );
 
+            if( msg != EQUIP_ERR_OK )                               // convert to possible store amount
 
+            count = noSpaceForCount;
 
+
 
+            if( count == 0 || dest.empty())                         // can't add any
 
             {
 
+              ChatHandler(this).PSendSysMessage( LANG_YOU_KILLED_NO_SPACE );
 
+              return true;
 
+            }
 
+
 
+            Item* item = StoreNewItem( dest, itemId, true, Item::GenerateItemRandomPropertyId(itemId));
 
+            ChatHandler(this).PSendSysMessage( LANG_YOU_KILLED );
 
+//pvp token end
 
+
 
+            {
 
                 // PLAYER_CHOSEN_TITLE VALUES DESCRIPTION
 
                 //  [0]      Just name
 
                 //  [1..14]  Alliance honor titles and player name


相关报道:

[关闭] [返回顶部]


  返回首页 | 最新资讯 | 资源下载 | 魔兽图片 | 单机文档 | 技术攻略 | 玩家视频
备案号:蜀ICP备2024062380号-1
免责声明:本网站为热爱怀旧WOW的玩家们建立的魔兽世界资料网站,仅供交流和学习使用,非盈利和商用.如有侵权之处,请联系我们,我们会在24小时内确认删除侵权内容,谢谢合作。
Copyright © 2024 - 2024 WOWAII.COM Corporation, All Rights Reserved

机器人国度