Abyssea NPC Help

Post Reply
soulsin
Posts: 102
Joined: Sun Mar 17, 2013 9:06 am

Abyssea NPC Help

Post by soulsin » Wed Aug 06, 2014 11:51 am

I have look at some other codes to give status effect, But I cant get to work on the abyssea NPC's
I made a Temp Command until able get it working, what like do able on zone in to abyssea it give status effect and on zone leave it take away. And status effect be abyssea only.

Code: Select all

-----------------------------------
-- Area: Abyssea Altepa
-- NPC: Atma Infusionist
-- Type: Standard NPC
-- @zone 218
-- @pos 412 -1 331 218
-----------------------------------
package.loaded["scripts/zones/Abyssea-Altepa/TextIDs"] = nil;
-----------------------------------

-----------------------------------
-- onTrade Action
-----------------------------------

function onTrade(player,npc,trade)
end;

-----------------------------------
-- onTrigger Action
-----------------------------------

function onTrigger(player,npc)
	player:startEvent(0x07D3);
end;

-----------------------------------
-- onEventUpdate
-----------------------------------

function onEventUpdate(player,csid,option)
	-- printf("CSID: %u",csid);
	-- printf("RESULT: %u",option);
end;

-----------------------------------
-- onEventFinish
-----------------------------------

function onEventFinish(player,csid,option)
	-- printf("CSID: %u",csid);
	-- printf("RESULT: %u",option);
	

end;

Here is the some status effect I like to use, but will add more and be abyssea only

Code: Select all

-- Add bonus effects to the player..
        player:addStatusEffect(EFFECT_MAX_HP_BOOST,100,0,0);
        player:addStatusEffect(EFFECT_MAX_MP_BOOST,100,0,0);
        player:addStatusEffect(EFFECT_SENTINEL,100,0,0);
        player:addStatusEffect(EFFECT_REGAIN,100,1,0);
        player:addStatusEffect(EFFECT_REFRESH,99,0,0);
        player:addStatusEffect(EFFECT_REGEN,99,0,0);
        
        -- Add bonus mods to the player..
        player:addMod(MOD_RACC,500);
        player:addMod(MOD_RATT,500);
        player:addMod(MOD_ACC,500);
        player:addMod(MOD_ATT,500);
        player:addMod(MOD_MATT,500);
        player:addMod(MOD_MACC,500);
        player:addMod(MOD_RDEF,500);
        player:addMod(MOD_DEF,500);
        player:addMod(MOD_MDEF,500);
        
        -- Heal the player from the new buffs..
        player:addHP( 50000 );
        player:setMP( 50000 );
    

        -- Remove bonus effects..
        player:delStatusEffect(EFFECT_MAX_HP_BOOST);
        player:delStatusEffect(EFFECT_MAX_MP_BOOST);
        player:delStatusEffect(EFFECT_SENTINEL);
        player:delStatusEffect(EFFECT_REGAIN);
        player:delStatusEffect(EFFECT_REFRESH);
        player:delStatusEffect(EFFECT_REGEN);
        
        -- Remove bonus mods..
        player:delMod(MOD_RACC,500);
        player:delMod(MOD_RATT,500);
        player:delMod(MOD_ACC,500);
        player:delMod(MOD_ATT,500);
        player:delMod(MOD_MATT,500);
        player:delMod(MOD_MACC,500);
        player:delMod(MOD_RDEF,500);
        player:delMod(MOD_DEF,500);
        player:delMod(MOD_MDEF,500);
[GM] Soulsin

Post Reply