Jump to content
MiniMan

Balanced Pk Map

Recommended Posts

Looking for someone who could help me to make balanced pk map
that's mean all the players will have same stats inside this map doesn't matter if he's gemmed or clean everyone will be with same stats

if someone can help me to do it pm me here or discord : MiniMan#9579

I can pay for the service thanks .

Share this post


Link to post
Share on other sites

Hi @MiniMan!

 

Q: How to make this work?
R: Simple, paste codes below at end of AttrCalculate.lua and call BalancedPkMap(role) at navtive function located at AttrCalculate.lua -> ExAttrSet(role) or use hooks.

 

Native function method
function ExAttrSet(role)

  if IsPlayer(role) == 1 then
    BalancedPkMap(role)
    -- Some codes heres
end

 

Hooking method, must have Hook Library by Matt
Hook:AddPostHook("ExAttrSet", BalancedPkMap)

 

Note¹: I didn't tested that, but may work.

 

NewPlayerAttrSet = {}
NewPlayerAttrSet.Attribute = {Max = {HP = 100, SP = 100}, Attack = {Min = 2000, Max = 2500, Speed = 250}, Defense = 500, Resist = 25, HitRate = 250, Dodge = 250, MoveSpeed = 600}


BalancedPkMap = function(Player)
	if GetChaMapName(Player) == "FarmMap" then
		if NewPlayerAttrSet.Attribute ~= nil then
			local mf_final = Mf_final(Player)	
			local crt_final = Crt_final(Player)
			local hrec_final = Hrec_final(Player)
			local srec_final = Srec_final(Player)
			local adis_final = Adis_final(Player)
			SetCharaAttr(NewPlayerAttrSet.Attribute.Max.HP, Player, ATTR_MXHP)
			SetCharaAttr(NewPlayerAttrSet.Attribute.Max.SP, Player, ATTR_MXSP)
			SetCharaAttr(NewPlayerAttrSet.Attribute.Attack.Min, Player, ATTR_MNATK)
			SetCharaAttr(NewPlayerAttrSet.Attribute.Attack.Max, Player, ATTR_MXATK)
			SetCharaAttr(NewPlayerAttrSet.Attribute.Defense, Player, ATTR_DEF )
			SetCharaAttr(NewPlayerAttrSet.Attribute.Resist, Player, ATTR_PDEF) 
			SetCharaAttr(NewPlayerAttrSet.Attribute.HitRate, Player, ATTR_HIT )
			SetCharaAttr(NewPlayerAttrSet.Attribute.Dodge, Player, ATTR_FLEE)
			SetCharaAttr(mf_final, Player, ATTR_MF )
			SetCharaAttr(crt_final, Player, ATTR_CRT )
			SetCharaAttr(hrec_final, Player, ATTR_HREC )
			SetCharaAttr(srec_final, Player, ATTR_SREC )
			SetCharaAttr(adis_final, Player, ATTR_ADIS )
			SetCharaAttr(NewPlayerAttrSet.Attribute.MoveSpeed, Player, ATTR_MSPD )
			SetCharaAttr(100000/NewPlayerAttrSet.Attribute.Attack.Speed, Player, ATTR_ASPD )	
		end
	end
end

 

Edited by Satan
Code fixing
  • Like 1

lelouch_signature_by_vahntheknight-d4uafwj.png

Share this post


Link to post
Share on other sites

Hello, @MiniMan!

 

Also do not forget about skills and items (cakes and other cook for example)


Share this post


Link to post
Share on other sites
On 4/3/2019 at 2:20 PM, V3ct0r said:

Hello, @MiniMan!

 

Also do not forget about skills and items (cakes and other cook for example)

Any clues on how to make skills that affect attributes work with this balanced map script? Ie. Abyss mire does not affect the attribute (decreases mspd) of player being affected. Thanks.

Edited by Myruni

Share this post


Link to post
Share on other sites
On 5/30/2023 at 11:39 PM, Myruni said:

Any clues on how to make skills that affect attributes work with this balanced map script? Ie. Abyss mire does not affect the attribute (decreases mspd) of player being affected. Thanks.

bump.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...