[REQUEST] PvP Script menu

Shout-Out

User Tag List

Results 1 to 8 of 8
  1. #1
    Blackboy0's Avatar Member
    Reputation
    70
    Join Date
    Nov 2007
    Posts
    377
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [REQUEST] PvP Script

    Alright, I need somebody to create me, or link me to a, C++ PvP Script.

    What I want it to do?

    I want it to do the following things:

    • When Level 79 and under, award 1 Token
    • When above Level 80, award 2 Tokens
    • When a player is killed by another Player that is within 10 levels, they are Whispered (In the box where they are Whispered, just put like "WHISPERMESSAGE IN HERE" and I will fill it in)
    • When a player kills another Player within 10 Levels, they are Whispered (In the box where they are whispered, just put "WHISPERMESSAGE IN HERE" and I will fill it in)
    • If not within 10 levels, both players are whispered. (Again, leave a message telling me where to put in the whisper)

    If you could make the Script somewhat easy to modify, that'd be great. There still some stuff that I want to add in, but I wanna do it myself. I wouldn't learn anything if I got one of you to do it all :P

    Anyways, if you create this I will thank you in any way I can.

    Thanks,
    Blackboy0

    [REQUEST] PvP Script
  2. #2
    Timzorize's Avatar Member
    Reputation
    9
    Join Date
    May 2008
    Posts
    206
    Thanks G/R
    1/0
    Trade Feedback
    0 (0%)
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Just do a for loop

  3. #3
    Blackboy0's Avatar Member
    Reputation
    70
    Join Date
    Nov 2007
    Posts
    377
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Timzorize View Post
    Just do a for loop
    ...eh? I don't know any C++, other than the real simple stuff.

  4. #4
    darkdragon555's Avatar Member
    Reputation
    1
    Join Date
    Mar 2007
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the for loop is has basic as it gets really!

  5. #5
    Cephalopod's Avatar Member
    Reputation
    5
    Join Date
    Sep 2008
    Posts
    85
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I don't get how a for loop achieves what he wants...

  6. #6
    Pragma's Avatar Contributor
    Reputation
    261
    Join Date
    Feb 2007
    Posts
    630
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    currently making...

    EDIT: Done!!!

    PM me if there any problems

    BlackBoyPVP.cpp:
    Code:
    /*
    Author: Pragma
    For: BlackBoy0
    */
    
    
    #include "StdAfx.h"
    #include "Setup.h"
    
    #define TOKENID 12345 //token ID
    
    
    void BBPVP(Player * pPlayer, Player * pVictim)
    {
        uint32 aLvl, vLvl;
        uint32 high, low;
    
        Item * pItem = objmgr.CreateItem(TOKENID, pPlayer);
        
        aLvl = pPlayer->getLevel();
        vLvl = pVictim->getLevel();
    
    
        if((aLvl >= vLvl))
        {
            high = aLvl;
            low = vLvl;
        }
        else
        {
            high = vLvl;
            low = aLvl;
        }
    
    
        if(aLvl <= 79)
        {
            pPlayer->GetItemInterface()->AddItemToFreeSlot(pItem);
        }
        else if(aLvl == 80)
        {
            pPlayer->GetItemInterface()->AddItemToFreeSlot(pItem);
            pPlayer->GetItemInterface()->AddItemToFreeSlot(pItem);
        }
    
        if((high - low) <= 10)  //if the level difference between the two players is 10 or less
        {
            pPlayer->BroadcastMessage("Whisper message here"); //message sent to the killer
            pVictim->BroadcastMessage("Whisper message here"); //message sent to the victim
        }
        else  //if the level difference is greater than 10
        {
            pPlayer->BroadcastMessage("Whisper message here"); //message sent to the killer
            pVictim->BroadcastMessage("Whisper message here"); //message sent to the victim
        }
    }
    
    
    void SetupBlackBoyPVP(ScriptMgr * mgr)
    {
        sLog.outString("BlackBoyPVP V1.0 Started!");
        mgr->register_hook(SERVER_HOOK_EVENT_ON_KILL_PLAYER, &BBPVP);
    }
    Setup.cpp:
    Code:
    #include "StdAfx.h"
    #include "Setup.h"
    #define SKIP_ALLOCATOR_SHARING 1
    #include <ScriptSetup.h>
    
    extern "C" SCRIPT_DECL uint32 _exp_get_script_type()
    {
        return SCRIPT_TYPE_MISC;
    }
    
    extern "C" SCRIPT_DECL void _exp_script_register(ScriptMgr* mgr)
    {
        SetupBlackBoyPVP(mgr);
    }
    
    #ifdef WIN32
    
    BOOL APIENTRY DllMain( HANDLE hModule, DWORD  ul_reason_for_call, LPVOID lpReserved )
    {
        return TRUE;
    }
    
    #endif
    Setup.h:
    Code:
    void BBPVP(Player * pPlayer, Player * pVictim);
    void SetupBlackBoyPVP(ScriptMgr * mgr);
    Last edited by Pragma; 01-26-2009 at 05:10 AM.


  7. #7
    Blackboy0's Avatar Member
    Reputation
    70
    Join Date
    Nov 2007
    Posts
    377
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Alright, so it does everything I asked for? I love you man
    +Rep as much as I can!!

  8. #8
    Pragma's Avatar Contributor
    Reputation
    261
    Join Date
    Feb 2007
    Posts
    630
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Tell me if there are any problems.


Similar Threads

  1. [Request] LUA Scripting
    By Creepfold in forum World of Warcraft Emulator Servers
    Replies: 12
    Last Post: 12-31-2007, 06:28 PM
  2. [Request] PvP gear
    By Buxton in forum World of Warcraft Emulator Servers
    Replies: 0
    Last Post: 12-11-2007, 02:31 PM
  3. request( pvp horde rogue superior> bloodfang
    By lord nikon in forum WoW ME Questions and Requests
    Replies: 1
    Last Post: 01-08-2007, 11:34 AM
  4. Request: PVP Sabre to Blue epic Elekk
    By Holyz in forum WoW ME Questions and Requests
    Replies: 2
    Last Post: 12-31-2006, 08:27 PM
All times are GMT -5. The time now is 01:05 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search