Fulqrum Publishing Home   |   Register   |   Today Posts   |   Members   |   UserCP   |   Calendar   |   Search   |   FAQ

Go Back   Official Fulqrum Publishing forum > Fulqrum Publishing > King's Bounty > King's Bounty: Armored Princess > Mods

Mods Armored Princess mods

Reply
 
Thread Tools Display Modes
  #1  
Old 04-23-2010, 04:27 PM
zubovsergei zubovsergei is offline
Registered Member
 
Join Date: Dec 2009
Posts: 15
Default

I am trying to edit the prayer ability in addon_special_attacks.lua and no matter what I change, nothing seems to change in the game. The prayer ability still damages demons and doesn't heal them.

DO I need to start a new game for changes in addon_special_attacks.lua to take place? I have edited other files so I know how to do it and everything else works okay.
Reply With Quote
  #2  
Old 04-23-2010, 08:36 PM
zini4_tha_grunt zini4_tha_grunt is offline
Approved Member
 
Join Date: Dec 2009
Posts: 83
Default

no. you haven't.
you should create a new lua file, paste source code for the hability and then edit it in that file. i advice simply delete checking for features.
Reply With Quote
  #3  
Old 04-23-2010, 09:04 PM
zubovsergei zubovsergei is offline
Registered Member
 
Join Date: Dec 2009
Posts: 15
Default

LIke I said, editing or deleting anything related to the prayer ability doesn't change anything. I even deleted the whole source code for the prayer ability and the ability was not changed at all. It still worked fine even though I deleted it. That is why I thought that I need to start a new game or something.
Reply With Quote
  #4  
Old 04-24-2010, 12:54 AM
N3MES1S N3MES1S is offline
Approved Member
 
Join Date: Nov 2009
Posts: 241
Default

I just used the prayer skill from the paladin to create another "prayer" style skill on my phoenix mod. It resurrect ALL units except undead, and undead doesnt suffer damage.

And like Zini4 said, dont modify the original files, create your own script files with a copy of the skill u want to use, and refer it in the atom file, look examples.

U dont need to start a new game, the final part of the code should be like this (this is my phoenix mod code, but healing/res all units):

function legendaryphoenix_resur()

Attack.aseq_remove(0)
Attack.act_aseq(0,"victory")

local pal_count = Attack.act_size(0)
local dmgts = Attack.aseq_time(0, "x") -- x time of attacker

Attack.atom_spawn(0, dmgts, "effect_lightpower")
dmgts1=0 --Attack.aseq_time(a, "x")

local ccnt = Attack.cell_count()
for i=0,ccnt-1 do

local tgt = Attack.cell_get(i)

if tgt~=nil and Attack.cell_dist(0,tgt)<=1 then
if Attack.act_ally(tgt) then

if (Attack.act_need_cure(tgt) or Attack.cell_need_resurrect(tgt)) and (Attack.act_ally(tgt) and not (Attack.act_feature(tgt,"golem,plant,mech,pawn,bos s"))) then
local min_dmg,max_dmg = text_range_dec(Attack.get_custom_param("heal"))
local heal = math.floor(Game.CurLocRand(min_dmg*pal_count,max_d mg*pal_count))*(1+tonumber(skill_power2("resurrect ion",2)/100))

local need = Attack.act_initsize(tgt)*Attack.act_get_par(tgt,"h ealth") - Attack.act_totalhp(tgt)
if need < 0 then need = Attack.act_get_par(tgt,"health") - Attack.act_hp(tgt) end
heal = math.min(need, heal)

local aa = Attack.atom_spawn(tgt, dmgts+dmgts1, "effect_total_cure")
local dmgts3 = Attack.aseq_time(aa, "x")
local count_old = Attack.act_size(tgt)

if need > 0 and Attack.cell_need_resurrect(tgt) then
Attack.cell_resurrect(tgt, heal, dmgts+dmgts1+dmgts3)
local n = Attack.act_size(tgt) - count_old
if n > 0 then
Attack.act_cure(tgt, -n, dmgts+dmgts1+dmgts3)
end
end


local d, label, slabel = Attack.act_size(tgt) - count_old
if Attack.act_size(tgt)>1 then slabel = "2" else slabel = "1" end
if d > 0 then label = "add_blog_res_"; heal = d else label = "add_blog_cure_" end
Attack.log(0.001, label..slabel, "target",blog_side_unit(tgt,0),"special",heal)
end
end
end
end


return true
end
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:26 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2007 Fulqrum Publishing. All rights reserved.