A EXP Differential script, Need some help. menu

User Tag List

Results 1 to 2 of 2
  1. #1
    sgtmas2006's Avatar Member
    Reputation
    7
    Join Date
    Oct 2007
    Posts
    103
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    A EXP Differential script, Need some help.

    I haven't been scripting for long, And am restarting my old server, And need some help scripting a Lua script to do a differential ammount of honor and Experience given Dependant on what level the player is, And the person they are killing's level.

    Contact me through this thread, Or on MSN: [email protected] , Or E-Mail me: [email protected]

    Thanks,
    -Killerry, And Destructed-WoW's Staff.

    A EXP Differential script, Need some help.
  2. #2
    covert_cat's Avatar Member
    Reputation
    55
    Join Date
    Sep 2009
    Posts
    96
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well, I've never made a script for this before but I'll give it a try. Just, for future help with lua, I think you'll find every page in this section VERY useful: http://www.arcemu.info/wiki/index.php?title=Lua

    Anyways, I IMAGINE it would be something like this:
    Code:
    function PvP_OnKill(event, pPlayer, pKilled)
    	local level = pPlayer:GetLevel()
    	local deadlevel = pKilled:GetLevel()
    	if (level <= 40) then
    	pPlayer:GiveHonor(level*deadlevel)
    	pPlayer:SendBroadcastMessage("Some honor for yous")
    	end
    	
    	if (level >= 41) then
    	pPlayer:GiveHonor(level*deadlevel*2)
    	pPlayer:SendBroadcastMessage("More honor for yous")
    	end
    end
    
    RegisterServerHook(2, "PvP_OnKill")
    Pretty much all this does(if it works!) is check the player's level when they kill someone, and then multiply that number by their dead opponent's level. If they are OVER level 40, then the result is doubled. The reason I didn't use 23(ON_HONORABLE_KILL) as my server hook is because I thought you may want players to be given honor even if they pwn a level 1. If you only want it to modify the honor given on honorable kills.. well, change the 2 to 23 I guess. And uhh, you can remove the broadcast message if you want. I just like stuff like that.

    I can't be sure about it working or not, because currently my server isn't public, so it's just me on there.. it's pretty lonely. xD
    If it works, you can play around with it to your liking. But really, read the wiki. It's amazingly helpful.

    If it doesn't work, oh well. I tried. :/
    Last edited by covert_cat; 07-26-2010 at 06:52 PM.

Similar Threads

  1. [Lua Script] Need some help with my lua script
    By riizu in forum WoW EMU Questions & Requests
    Replies: 4
    Last Post: 07-13-2010, 01:40 AM
  2. Need some Help with a script of mine! not working and i dont know why.
    By Flesh0209 in forum WoW EMU Questions & Requests
    Replies: 3
    Last Post: 08-08-2009, 08:10 PM
  3. Need some help with LUA script
    By SupernovaHH in forum WoW EMU Questions & Requests
    Replies: 2
    Last Post: 07-22-2009, 07:25 AM
  4. Noob LUA script, need some help.
    By pancakebuddy in forum World of Warcraft Emulator Servers
    Replies: 5
    Last Post: 05-14-2008, 08:33 AM
  5. [Request] I need some help with lua script (boss on death)
    By Ellenor in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 03-03-2008, 03:47 PM
All times are GMT -5. The time now is 05:13 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