[help] Need some assistance with Ascent. menu

User Tag List

Results 1 to 3 of 3
  1. #1
    Krendol's Avatar Member
    Reputation
    6
    Join Date
    Jan 2008
    Posts
    32
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [help] Need some assistance with Ascent.

    Hey guys

    I'm a GM on a friend's server, and we're just setting it up before players come on, and we could do with some help.


    1. How do you make players get a token after killing a player? (PvP tokens, for PvP gear)

    2. The admin can't connect to her DB from another computer, she has all the info right, and firewall's sorted etc, but she can't connect, she gets a "Cannot connect to XXX" error.

    Sorry if i'm being a bit hazy on the information, but if you could post a thread for question 1, that's still fine. And yes, I have searched, and looked through some FAQ's but not found anything.

    '.'.'.'Krendol '.'.'.'

    [help] Need some assistance with Ascent.
  2. #2
    soul02's Avatar Active Member
    Reputation
    33
    Join Date
    Mar 2008
    Posts
    168
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    1.
    Code:
    #include "StdAfx.h"
    #include "Setup.h"
    
    void onPvpKill(Player* plr, Player* victim)
    {
    int itemID;
    uint32 tokenItem = Config.MainConfig.GetInt("NCDB", "PvPTokenID", &itemID);
    
    sLog.outColor(TGREEN,"n[NCDB] (%u)%s killed (%u)%s", plr->getLevel(), plr->GetName(), victim->getLevel(), victim->GetName());
    
    if(plr->getLevel() >= 19 && victim->getLevel() >= 19 && plr->GetTeam() != victim->GetTeam())
    {
    sLog.outColor(TGREEN,"n[NCDB] Adding token to %s", plr->GetName());
    sLog.outColor(TNORMAL,"n");
    ItemPrototype *proto = ItemPrototypeStorage.LookupEntry(itemID);
    SlotResult slotresult;
    slotresult = plr->GetItemInterface()->FindFreeInventorySlot(proto);
    
    if(!slotresult.Result)
    {
    plr->GetItemInterface()->BuildInventoryChangeError(NULL, NULL, INV_ERR_INVENTORY_FULL);
    }
    else
    {
    Item *itm = objmgr.CreateItem(itemID, plr);
    itm->SetUInt32Value(ITEM_FIELD_STACK_COUNT, 1);
    plr->GetItemInterface()->SafeAddItem(itm,slotresult.ContainerSlot, slotresult.Slot);
    plr->SaveToDB(false);
    }
    }
    else
    {
    sLog.outColor(TGREEN,"n[NCDB] Not adding token since they both are not level 70");
    sLog.outColor(TNORMAL,"n");
    }
    }
    
    void SetupPvPToken(ScriptMgr * mgr)
    {
    mgr->register_hook(SERVER_HOOK_EVENT_ON_KILL_PLAYER, onPvpKill);
    }
    2. http://www.mmowned.com/forums/emulat...-database.html
    -·=»‡«=·- Soul02 -·=»‡«=·-


  3. #3
    Krendol's Avatar Member
    Reputation
    6
    Join Date
    Jan 2008
    Posts
    32
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thank you very much. I'll tell you if either of these work.

    And I feel really stupid at the moment, but hey.

    hehe

    '.'.'.'Krendol '.'.'.'

Similar Threads

  1. Need some assistance with gold sale
    By Aniecheres in forum World of Warcraft General
    Replies: 6
    Last Post: 04-18-2010, 02:03 PM
  2. Need Lil Help Error Been While With Ascent
    By [Shon3m] in forum World of Warcraft Emulator Servers
    Replies: 6
    Last Post: 05-20-2008, 06:18 PM
  3. [Help] GRR... always error with ascent.exe
    By LordJedi in forum World of Warcraft Emulator Servers
    Replies: 7
    Last Post: 02-15-2008, 07:46 PM
  4. [Help] Need some DB's and SQL files..
    By UnKnowN- in forum World of Warcraft Emulator Servers
    Replies: 6
    Last Post: 11-22-2007, 12:22 AM
All times are GMT -5. The time now is 02:27 PM. 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