• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[Request] TFS 3.6.1 Scripts

Onizuka

Member
Joined
Jul 5, 2008
Messages
2,291
Reaction score
14
Hi, So i am half way making a pvp-e server, quite stable, non-buggy etc etc..



I am in a big need of few scripts to make it perfect, so hopefully someone nice enough is willing to help out :]




1. Script that does not give exp to same IP killer, what it means that P1 kills P2 and if they have the same IP, then P1 does not get any exp.




2. I got pvp set from lvl 1 and i want to keep it that way, what i don't want is noobs blocking and screwing up wars/pks.
What i need is a creature or login script, that if Player dies under lvl 50 then no unjust for higher lvl. He should get skull but not get unjust frag for it.



//Thanks
 
1. double Player::getGainedExperience(Creature* attacker) const add:

Code:
if(getIP() == attacker->getIP())
	return 0;

2. bool Player::addUnjustifiedKill(const Player* attacked, bool countNow) add:

Code:
if(attacked->getLevel() < 50)
	return false;
 
@1st Script Like this?
Lua:
function onKill(cid, target)
        if isPlayer(target) == TRUE then
		if getPlayerIp(cid) ~= getPlayerIp(target) then
        loot = 8698
	  item = doPlayerAddItem(cid,loot,1)
	elseif getPlayerName(cid) == getPlayerName(target) then
	  doPlayerAddItem(cid,loot,1)
                  doSetItemSpecialDescription(item,"It was awarded to "..getCreatureName(cid).." at level "..getPlayerLevel(cid).." for killing "..getCreatureName(target).." at level "..getPlayerLevel(target)..".")
else
		doPlayerAddExperience(cid, -10000)
		doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE,"You have been punished for killing a player of the same IP.")
        end
end
        return TRUE
end
Ops, didnt check the date lol
 
Back
Top