Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

Need this pls help :(

Newbie Spellweaver
Joined
May 21, 2011
Messages
44
Reaction score
0
Please i need help to find thos script or how to make :
-Npc Buffer
-Npc sell uns eqp lv 45-55-65
-Npc sell Ring and neck...
Please help me :*:
any help will be greatly
sorry my bad eng^^
thanks for advance.
 
Junior Spellweaver
Joined
Jan 5, 2009
Messages
128
Reaction score
12
Buffer NPC

resource \ script \ calculate \ forge.lua

Add to end of file

Code:
  - Buffer
 function NewbieBuff1 (role)

         local money = HasMoney (role, 1000) - Check for the right amount of gold (by default 1000)
        
         if money == 0 then - If the amount is not enough,
                 SystemNotice (role, "Do you have enough gold!") - Display system message about the lack of gold
         end
        
         local StateType = GetChaStateLv (role, STATE_QINGZ) - Check if already imposed this buff
         if StateType == 0 then - if not imposed, then
                 AddState (role, role, STATE_QINGZ, 15, 300) - Apply the state STATE_QINGZ in character for a period of 300 seconds (5 minutes), with a level of status 15 (not me!)
                 TakeMoney (role, nil, 1000) - To select a character 1000 gold
                 SystemNotice (role, "Blessing received a beginner, your defense is increased by 20 points in 5 minutes!") - Display system message about the successful application of the buff
         else - Otherwise
                 SystemNotice (role, "You already have the blessing freshman!") - Display a message that buff on the player already has been imposed
         end
 end

 function NewbieBuff2 (role)

         local money = HasMoney (role, 1000)
        
         if money == 0 then
                 SystemNotice (role, "Do you have enough gold!")
         end
        
         local StateType = GetChaStateLv (role, STATE_QINGZ)
         if StateType == 0 then
                 AddState (role, role, STATE_QINGZ, 16, 300)
                 TakeMoney (role, nil, 1000)
                 SystemNotice (role, "Blessing received a beginner, your attack is increased by 10 points in 5 minutes!")
         else
                 SystemNotice (role, "You already have the blessing freshman!")
         end
 end

 function NewbieBuff3 (role)

         local money = HasMoney (role, 1000)
        
         if money == 0 then
                 SystemNotice (role, "Do you have enough gold!")
         end
        
         local StateType = GetChaStateLv (role, STATE_QINGZ)
         if StateType == 0 then
                 AddState (role, role, STATE_QINGZ, 17, 300)
                 TakeMoney (role, nil, 1000)
                 SystemNotice (role, "Blessing received a beginner, your standard of living increased by 50 points in 5 minutes!")
         else
                 SystemNotice (role, "You already have the blessing freshman!")
         end
 end

 function StandartBuff1 (role)

         local money = HasMoney (role, 10000)
        
         if money == 0 then
                 SystemNotice (role, "Do you have enough gold!")
         end
        
         local StateType = GetChaStateLv (role, STATE_XLZH)
         if StateType == 0 then
                 AddState (role, role, STATE_XLZH, 10, 300) - Apply the state STATE_XLZH (Ghost fire) 10lvl for a period of 300 seconds (5 minutes).  Here the level of state can be changed.  The level of the state will match the level of the overlay spells.
                 TakeMoney (role, nil, 10000)
                 SystemNotice (role, "Ghost imposed 10lvl fire for 5 minutes!")
         else
                 SystemNotice (role, "You can not use a combination of two spells of the same type!")
         end
 end

 function StandartBuff2 (role)

         local money = HasMoney (role, 10000)
        
         if money == 0 then
                 SystemNotice (role, "Do you have enough gold!")
         end
        
         local StateType = GetChaStateLv (role, STATE_SHPF)
         if StateType == 0 then
                 AddState (role, role, STATE_SHPF, 10, 300)
                 TakeMoney (role, nil, 10000)
                 SystemNotice (role, "Hardening 10lvl imposed for 5 minutes!")
         else
                 SystemNotice (role, "You can not use a combination of two spells of the same type!")
         end
 end

 function StandartBuff3 (role)

         local money = HasMoney (role, 10000)
        
         if money == 0 then
                 SystemNotice (role, "Do you have enough gold!")
         end
        
         local StateType = GetChaStateLv (role, STATE_TSHD)
         if StateType == 0 then
                 AddState (role, role, STATE_TSHD, 10, 300)
                 TakeMoney (role, nil, 10000)
                 SystemNotice (role, "Angelic Shield 10lvl imposed for 5 minutes!")
         else
                 SystemNotice (role, "You can not use a combination of two spells of the same type!")
         end
 end

 function StandartBuff4 (role)

         local money = HasMoney (role, 10000)
        
         if money == 0 then
                 SystemNotice (role, "Do you have enough gold!")
         end
        
         local StateType = GetChaStateLv (role, STATE_MLCH)
         if StateType == 0 then
                 AddState (role, role, STATE_MLCH, 10, 300)
                 TakeMoney (role, nil, 10000)
                 SystemNotice (role, "superimposed intense magic 10lvl for 5 minutes!")
         else
                 SystemNotice (role, "You can not use a combination of two spells of the same type!")
         end
 end
 -------------------------------------------------- -------------------------------
 --------

resource \ script \ MisSdk \ NpcSdk.lua

Find the file line

Code:
 if item.func == JumpPage then
                         return JumpPage (character, npc, page, item.p1)

And add below

Code:
 elseif item.func == NewbieBuff1 then
                         return NewbieBuff1 (character)
                 elseif item.func == NewbieBuff2 then
                         return NewbieBuff2 (character)
                 elseif item.func == NewbieBuff3 then
                         return NewbieBuff3 (character)
                 elseif item.func == StandartBuff1 then
                         return StandartBuff1 (character)
                 elseif item.func == StandartBuff2 then
                         return StandartBuff2 (character)
                 elseif item.func == StandartBuff3 then
                         return StandartBuff3 (character)
                 elseif item.func == StandartBuff4 then
                         return StandartBuff4 (character)
resource \ script \ MisScript \ NpcScript01.lua ( any NpcScript.. )

Add to end of file

Code:
function d_talk021 ()
         Talk (1, "Priest: Greetings in the name of the gods. Can I help than that?")
         Text (1, "I want to get the blessing freshman.", JumpPage, 2)
         Text (1, "I want to spell improves.", JumpPage, 3)
         Text (1, "Goodbye", CloseTalk)
        
         Talk (2, "Priest: the favor of the gods to achieve is not so easy. You are ready to donate 1000 gold coins in the name of glory?")
         Text (2, "Strengthen my body (20 defense)", NewbieBuff1, 1)
         Text (2, "Help defeat the enemies (10 attacks)", NewbieBuff2, 1)
         Text (2, "Give me the will to live (50 lives)", NewbieBuff3, 1)
         Text (2, "Back", JumpPage, 1)
        
         Talk (3, "Priest: Not enough power for the next feat? I can help you, but my services are worth the money. Be prepared to pay me 10 thousand gold coins.")
         Text (3, "Get Ghost Fire", StandartBuff1, 1)
         Text (3, 'Get hardening ", StandartBuff2, 1)
         Text (3, 'Get Angelic Shield ", StandartBuff3, 1)
         Text (3, 'Get the Intensive magic ", StandartBuff4, 1)
         Text (3, "Back", JumpPage, 1)
 end

resource \ garner \ garnerNPC.txt

Add to end of file

Code:
  Buffer 176 1 11 15 220300.277400 220300.277400 270 Argent City 1 0 0 d_talk021

resource \ script \ calculate \ skilleffect.lua

Find and replace function State_QINGZ_Add all content on

Code:
 function State_QINGZ_Add (role, statelv)
         if statelv == 15 then
                 local defens = GetChaAttr (role, ATTR_STATEV_DEF) 
                 local def_dif = 20 - How much protection will be added
                 local def = defens + def_dif
                 SetCharaAttr (def, role, ATTR_STATEV_DEF)
                 ALLExAttrSet (role)
                 RefreshCha (role)
         elseif statelv == 16 then
                 local minattack = GetChaAttr (role, ATTR_STATEV_MNATK)
                 local maxattack = GetChaAttr (role, ATTR_STATEV_MXATK)
                 local mnatksa_dif = 10 - How many minutes.  attacks will be added
                 local mxatksa_dif = 10 - How many max.  attacks will be added
                 local mnattack = minattack + mnatksa_dif
                 local mxattack = maxattack + mxatksa_dif
                 SetCharaAttr (mnattack, role, ATTR_STATEV_MNATK) 
                 SetCharaAttr (mxattack, role, ATTR_STATEV_MXATK) 
                 ALLExAttrSet (role)
                 RefreshCha (role)
         elseif statelv == 17 then
                 local hp = GetChaAttr (role, ATTR_STATEV_MXHP)
                 local hp_dif = 50 - How many lives will be added
                 local newhp = hp + hp_dif
                 SetCharaAttr (hp_dif, role, ATTR_STATEV_MXHP) 
                 ALLExAttrSet (role)
                 RefreshCha (role)
         else
                 local mspdsa_dif = 0.3
                 local def_dif = 50
                 local mspdsa = MspdSa (role)
                 local mspdsa_fin = (mspdsa + mspdsa_dif) * ATTR_RADIX
                 local defsb = DefSb (role) - def_dif
                 SetCharaAttr (defsb, role, ATTR_STATEV_DEF)
                 SetCharaAttr (mspdsa_fin, role, ATTR_STATEC_MSPD)
                 ALLExAttrSet (role)
                 RefreshCha (role)
         end
 end 



Then the following function is replaced by State_QINGZ_Rem

  function State_QINGZ_Rem (role, statelv)
         if statelv == 15 then
                 local defens = GetChaAttr (role, ATTR_STATEV_DEF) 
                 local def_dif = 20
                 local def = defens - def_dif
                 SetCharaAttr (def, role, ATTR_STATEV_DEF)
                 ALLExAttrSet (role)
                 RefreshCha (role)
         elseif statelv == 16 then
                 local minattack = GetChaAttr (role, ATTR_STATEV_MNATK)
                 local maxattack = GetChaAttr (role, ATTR_STATEV_MXATK)
                 local mnatksa_dif = 10
                 local mxatksa_dif = 10
                 local mnattack = minattack - mnatksa_dif
                 local mxattack = maxattack - mxatksa_dif
                 SetCharaAttr (mnattack, role, ATTR_STATEV_MNATK) 
                 SetCharaAttr (mxattack, role, ATTR_STATEV_MXATK) 
                 ALLExAttrSet (role)
                 RefreshCha (role)
         elseif statelv == 17 then
                 local hp = GetChaAttr (role, ATTR_STATEV_MXHP)
                 local hp_dif = 50
                 local newhp = hp - hp_dif
                 SetCharaAttr (hp_dif, role, ATTR_STATEV_MXHP) 
                 ALLExAttrSet (role)
                 RefreshCha (role)
         else
                 local mspdsa_dif = 0.3
                 local def_dif = 50
                 local mspdsa = MspdSa (role)
                 local mspdsa_fin = (mspdsa - mspdsa_dif) * ATTR_RADIX
                 local defsb = DefSb (role) + def_dif
                 SetCharaAttr (defsb, role, ATTR_STATEV_DEF)
                 SetCharaAttr (mspdsa_fin, role, ATTR_STATEC_MSPD)
                 ALLExAttrSet (role)
                 RefreshCha (role)
         end
 end

resource \ script \ calculate \ skilleffect.lua

Find it function State_Xlzh_Add, then this function find the line ALLExAttrSet (role). Add after this line below RefreshCha (role)
As a result, you should get so

Code:
function State_Xlzh_Add (role, statelv) 
         - LG ("state_xlzh", "function State_xlzh_Add:", "role =", role, "statelv =", statelv, "\ n") 
         local mnatksa_dif = 0.1 + 0.01 * statelv 
         local mxatksa_dif = 0.1 + 0.01 * statelv
         local mnatksa = math.floor ((MnatkSa (role) + mnatksa_dif) * ATTR_RADIX) 
         local mxatksa = math.floor ((MxatkSa (role) + mxatksa_dif) * ATTR_RADIX) 
         SetCharaAttr (mnatksa, role, ATTR_STATEC_MNATK) 
         SetCharaAttr (mxatksa, role, ATTR_STATEC_MXATK) 
         ALLExAttrSet (role) 
         RefreshCha (role)
 end

Now do the same thing with the following functions

State_Shpf_Add
State_Tshd_Add
The Buffer NPC will be in Argent

---------- Post added at 11:42 AM ---------- Previous post was at 11:39 AM ----------

Unseal NPC . This script is for unseal NPC level 65-85 i think its one of my old NPC but you will get the ideea and make ur own from this script:

Add the following to any NpcScript for example NpcScript04 or anywhere:

Code:
function Dbz_0018 ()

Talk( 1, "Hi, I sell unseals here, take a look." )
	Text( 1, "Buy Unseals", BuyPage)
InitTrade()
	Weapon(	0763  )
	Weapon(	0764  )
	Weapon(	0765  )
	Weapon( 0766  )
        Weapon(	0767  )
	Weapon(	0768  )
        Weapon( 0769  )
	Weapon(	0770  )
	Weapon(	0771  )
	Weapon(	0772  )
	Weapon(	0774  )
	Weapon(	0775  )
        Weapon( 0776  )
	Weapon(	0777  )
	Weapon(	0778  )
	Weapon(	0779  )
        Weapon( 0780  )
	Weapon(	0781  )
	Weapon(	0782  )
	Weapon(	0783  )
        Weapon( 0784  )
	Weapon(	0785  )
	Weapon(	0786  )
	Weapon(	0787  )
        Weapon( 0788  )
	Weapon(	0789  )
	Weapon(	0790  )
	Weapon(	0791  )
        Weapon( 0792  )
	Weapon(	0793  )
	Weapon(	0794  )
        Weapon( 0795  )
	Weapon(	0796  )
	Weapon(	0797  )
        Weapon( 0798  )
	Weapon(	0799  )
	Weapon(	0800  )
	Weapon(	0801  )
        Weapon( 0802  )
	Weapon(	0803  )
	Weapon(	0804  )
	Weapon(	0805  )
        Weapon( 0806  )
	Weapon(	0807  )
	Weapon(	0808  )
	Weapon(	0809  )
	Weapon(	0810  )
	Weapon(	0811  )
	Weapon(	0812  )
	Weapon(	0813  )
	Weapon(	0814  )
	Weapon(	0815  ) 
	Weapon(	3416  )
	Weapon(	3417  )
	Weapon(	3418  )
	Weapon(	3419  )
	Weapon(	3420  )
	Weapon(	3421  )
          Weapon( 0773  )
          Weapon( 2331 ) -> Darkness Emissary
          Weapon( 2332 ) -> Darkness Emissary
          Weapon( 2333 ) -> Tear of Hardin
          Weapon( 2334 ) -> Tear of Hardin
          Weapon( 2335 ) -> Penitent of Asura
          Weapon( 2336 ) -> Penitent of Asura
          Weapon( 2337 ) -> Abaddon Vanquisher
          Weapon( 2338 ) -> Abaddon Vanquisher
          Weapon( 2339 ) -> Kiss of Death
          Weapon( 2340 ) -> Kiss of Death
          Weapon( 2341 ) -> Putrescence Bone of Abyss
          Weapon( 2342 ) -> Putrescence Bone of Abyss
          Weapon( 2343 ) -> Vow of Styx
          Weapon( 2344 ) -> Vow of Styx
	Weapon(2817) -> Hardin's Bind
	Weapon(28180 -> Hardin's Touch
	Weapon(2819 )-> Hardin's Print
	Weapon(2820 )-> Darkness's Shadow
	Weapon(2821 )-> Darkness's Touch
	Weapon(2822 )-> Darkness's Trace
	Weapon(2823 )-> Abaddon's Seal
	Weapon(2824 )-> Abaddon's Hand
	Weapon(2825 )-> Abaddon's Brace
	Weapon(2826 )-> Asura's Protection
	Weapon(2827 )-> Asura's Caress
	Weapon(2828 )-> Asura's Dance
	Weapon(2829 )-> Abyss's Possession
	Weapon(2830 )-> Hands of Death
	Weapon(2831 )-> Abyss's Trail
	Weapon(2832 )-> Styx's Torso
	Weapon(2833 )-> Styx's Span
	Weapon(2834 )-> Styx's Wanderer
	Weapon(4274
	Weapon(4274 )
	Weapon(4275)
	Weapon(4276)
	Weapon(4277)
	Weapon(4278)
	Weapon(4279)
	Weapon(4280)
	Weapon(4281)
	Weapon(4282)
	Weapon(5880)
	Weapon(5881)
	Weapon(5882)
	Weapon(5883)
	Weapon(5884)
	Weapon(5885)
end

You can do the same for rings/necks too just change the IDs
 
Newbie Spellweaver
Joined
May 21, 2011
Messages
44
Reaction score
0
Can u please tell me how to put thos thing and also where? tnx
 
Back
Top