1
Fork 0
mirror of https://bitbucket.org/Ioncannon/project-meteor-server.git synced 2025-04-20 11:47:48 +00:00

Fixed args on commands due to triggername becoming eventType and eventName

This commit is contained in:
Filip Maj 2022-03-04 22:55:30 -05:00
parent bf20993e58
commit a618e69dbd
57 changed files with 83 additions and 109 deletions

View file

@ -13,7 +13,7 @@ local attackMagicHandlers = {
} }
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Ability(command.Id, targetActor); player.Ability(command.Id, targetActor);
player:endEvent(); player:endEvent();
end end

View file

@ -1,5 +1,5 @@
require("global") require("global")
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
end end

View file

@ -13,7 +13,7 @@ local attackMagicHandlers = {
} }
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Ability(command.Id, targetActor); player.Ability(command.Id, targetActor);
player:endEvent(); player:endEvent();

View file

@ -13,7 +13,7 @@ local attackMagicHandlers = {
} }
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();
end; end;

View file

@ -9,7 +9,7 @@ Finds the correct weaponskill subscript to fire when a weaponskill actor is acti
--]] --]]
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
--Are they in active mode? --Are they in active mode?
if (player:GetState() != 2) then if (player:GetState() != 2) then

View file

@ -8,7 +8,7 @@ Handles what happens when you examine a player's bazaar
require ("global") require ("global")
function onEventStarted(player, actor, triggerName, name, arg1, arg2, arg3, bazaarActorId) function onEventStarted(player, actor, eventType, eventName, name, arg1, arg2, arg3, bazaarActorId)
local bazaarActor = nil; local bazaarActor = nil;

View file

@ -20,7 +20,7 @@ seekAmount: The amount of seekItem we want.
require ("global") require ("global")
function onEventStarted(player, actor, triggerName, rewardItem, seekItem, bazaarMode, arg1, bazaarActor, rewardAmount, seekAmount, arg2, arg3, type9ItemIds) function onEventStarted(player, actor, eventType, eventName, rewardItem, seekItem, bazaarMode, arg1, bazaarActor, rewardAmount, seekAmount, arg2, arg3, type9ItemIds)
local rewarding = nil; local rewarding = nil;
local seeking = nil; local seeking = nil;

View file

@ -10,7 +10,7 @@ All bazaar args have a Reward (The item the person who fufills the request gets)
--TODO REFACTOR --TODO REFACTOR
function onEventStarted(player, actor, triggerName, rewardItem, seekItemOrCost, seekAmount, arg1, bazaarActorId, rewardAmount, rewardItemId, nameIndex, arg2, type9ItemIds) function onEventStarted(player, actor, eventType, eventName, rewardItem, seekItemOrCost, seekAmount, arg1, bazaarActorId, rewardAmount, rewardItemId, nameIndex, arg2, type9ItemIds)
local originalReward = nil; local originalReward = nil;
local originalSeek = nil; local originalSeek = nil;

View file

@ -13,7 +13,7 @@ Handles canceling bazaar items
--]] --]]
function onEventStarted(player, actor, triggerName, rewardItem, seekItem, bazaarType, narg, bazaarActor, rewardAmount, seekAmount, narg, narg, type9ItemIds) function onEventStarted(player, actor, eventType, eventName, rewardItem, seekItem, bazaarType, narg, bazaarActor, rewardAmount, seekAmount, narg, narg, type9ItemIds)
GetWorldManager():RemoveFromBazaar(player, player:GetItem(rewardItem)); GetWorldManager():RemoveFromBazaar(player, player:GetItem(rewardItem));

View file

@ -10,7 +10,7 @@ operateUI(pointsAvailable, pointsLimit, str, vit, dex, int, min, pie)
require ("global") require ("global")
function onEventStarted(player, actor, triggerName) function onEventStarted(player, actor, eventType, eventName)
--local points = player:GetAttributePoints(); --local points = player:GetAttributePoints();
--player:RunEventFunction("delegateCommand", actor, "operateUI", points.available, points.limit, points.inSTR, points.inVIT, points.inDEX, points.inINT, points.inMIN, points.inPIT); --player:RunEventFunction("delegateCommand", actor, "operateUI", points.available, points.limit, points.inSTR, points.inVIT, points.inDEX, points.inINT, points.inMIN, points.inPIT);
result = callClientFunction(player, "delegateCommand", actor, "operateUI", 100, 100, 10, 10, 10, 10, 10, 10); result = callClientFunction(player, "delegateCommand", actor, "operateUI", 100, 100, 10, 10, 10, 10, 10, 10);

View file

@ -1,4 +1,4 @@
function onEventStarted(player, caller, commandRequest, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) function onEventStarted(player, caller, eventType, eventName, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8)
player:SetCurrentJob(17); player:SetCurrentJob(17);

View file

@ -6,7 +6,7 @@ Handles player examining someone
--]] --]]
function onEventStarted(player, commandactor, triggerName, arg1, arg2, arg3, arg4, checkedActorId) function onEventStarted(player, commandactor, eventType, eventName, arg1, arg2, arg3, arg4, checkedActorId)
actor = player:GetActorInInstance(checkedActorId); actor = player:GetActorInInstance(checkedActorId);

View file

@ -8,9 +8,7 @@ Handles mounting and dismounting the Chocobo and Goobbue
require ("global") require ("global")
function onEventStarted(player, actor, triggerName, isGoobbue) function onEventStarted(player, actor, eventType, eventName, isGoobbue)
<<<<<<< HEAD
if (player:GetState() == 0) then if (player:GetState() == 0) then
worldMaster = GetWorldMaster(); worldMaster = GetWorldMaster();
@ -46,47 +44,5 @@ function onEventStarted(player, actor, triggerName, isGoobbue)
player:ChangeSpeed(0.0, 2.0, 5.0, 5.0) player:ChangeSpeed(0.0, 2.0, 5.0, 5.0)
player:ChangeState(0); player:ChangeState(0);
end end
player:EndEvent(); player:EndEvent();
=======
if (player:GetState() == 0) then
worldMaster = GetWorldMaster();
if (isGoobbue ~= true) then
player:ChangeMusic(83);
player:SendGameMessage(player, worldMaster, 26001, 0x20);
player:SetMountState(1);
else
player:ChangeMusic(98);
player:SendGameMessage(player, worldMaster, 26019, 0x20);
player:SetMountState(2);
end
player:ChangeSpeed(0.0, 5.0, 10.0, 10.0);
player:ChangeState(15);
else
player:ChangeMusic(player.CurrentArea.bgmDay);
worldMaster = GetWorldMaster();
if (player.rentalExpireTime != 0) then
player:SendGameMessage(player, worldMaster, 26004, 0x20); --You dismount.
else
if (player:GetMountState() == 1) then
player:SendGameMessage(player, worldMaster, 26003, 0x20); --You dismount X.
else
player:SendGameMessage(player, worldMaster, 26021, 0x20); --You dismount your Gobbue.
end
end
player:SetMountState(0);
player:ChangeSpeed(0.0, 2.0, 5.0, 5.0)
player:ChangeState(0);
end
player:EndEvent();
>>>>>>> ioncannon/quest_system
end end

View file

@ -124,7 +124,7 @@ local weaponskillHandlers = {
[0xA0F070EA] = nil [0xA0F070EA] = nil
} }
function onEventStarted(player, command, triggerName) function onEventStarted(player, command, eventType, eventName)
--Are they in active mode? --Are they in active mode?
if (player:GetState() != 2) then if (player:GetState() != 2) then

View file

@ -6,7 +6,7 @@ Handles what happens when you resolve an invite to a group
--]] --]]
function onEventStarted(player, actor, triggerName, groupType, result) function onEventStarted(player, actor, eventType, eventName, groupType, result)
--Accept/Refuse happened, else just close the window --Accept/Refuse happened, else just close the window
if (result == 1 or result == 2) then if (result == 1 or result == 2) then

View file

@ -6,7 +6,7 @@ Handles what happens when you accept/refuse a trade
--]] --]]
function onEventStarted(player, actor, triggerName, groupType, result) function onEventStarted(player, actor, eventType, eventName, groupType, result)
--Accept --Accept
if (result == 1) then if (result == 1) then

View file

@ -156,7 +156,7 @@ local skillAnim = {
local craftStartWidgetOpen = false; local craftStartWidgetOpen = false;
function onEventStarted(player, commandactor, triggerName, arg1, arg2, arg3, arg4, checkedActorId) function onEventStarted(player, commandactor, eventType, eventName, arg1, arg2, arg3, arg4, checkedActorId)
local MENU_CANCEL, MENU_MAINHAND, MENU_OFFHAND, MENU_REQUEST = 0, 1, 2, 3; local MENU_CANCEL, MENU_MAINHAND, MENU_OFFHAND, MENU_REQUEST = 0, 1, 2, 3;
local MENU_RECENT, MENU_AWARDED, MENU_RECENT_DETAILED, MENU_AWARDED_DETAILED = 7, 8, 9, 10; local MENU_RECENT, MENU_AWARDED, MENU_RECENT_DETAILED, MENU_AWARDED_DETAILED = 7, 8, 9, 10;

View file

@ -1,4 +1,4 @@
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();

View file

@ -1,4 +1,4 @@
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();

View file

@ -9,7 +9,7 @@ Finds the correct weaponskill subscript to fire when a weaponskill actor is acti
--]] --]]
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
--Are they in active mode? --Are they in active mode?
if (player:GetState() != 2) then if (player:GetState() != 2) then

View file

@ -4,7 +4,7 @@ DiceCommand Script
--]] --]]
function onEventStarted(player, actor, triggerName, maxNumber) function onEventStarted(player, actor, eventType, eventName, maxNumber)
if (maxNumber == nil or maxNumber > 1000 or maxNumber < 1) then if (maxNumber == nil or maxNumber > 1000 or maxNumber < 1) then
maxNumber = 100; maxNumber = 100;

View file

@ -99,7 +99,7 @@ nodeItems = {
require ("global") require ("global")
function onEventStarted(player, commandActor, triggerName, arg1, arg2, arg3, arg4, checkedActorId) function onEventStarted(player, commandActor, eventType, eventName, arg1, arg2, arg3, arg4, checkedActorId)
debugMsg = false; debugMsg = false;

View file

@ -1,4 +1,4 @@
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();

View file

@ -4,7 +4,7 @@ EmoteSitCommand Script
--]] --]]
function onEventStarted(player, actor, triggerName, emoteId) function onEventStarted(player, actor, eventType, eventName, emoteId)
if (player:GetState() == 0) then if (player:GetState() == 0) then
if (emoteId == 0x2712) then if (emoteId == 0x2712) then

View file

@ -6,7 +6,7 @@ require ("global")
--commandid: command being equipped --commandid: command being equipped
function onEventStarted(player, equipAbilityWidget, triggername, slot, commandid, unkown, arg1, arg2, arg3, arg4, arg5, arg6) function onEventStarted(player, equipAbilityWidget, eventType, eventName, slot, commandid, unkown, arg1, arg2, arg3, arg4, arg5, arg6)
local worldManager = GetWorldManager(); local worldManager = GetWorldManager();
local ability = worldManager:GetBattleCommand(commandid); local ability = worldManager:GetBattleCommand(commandid);

View file

@ -53,7 +53,7 @@ GRAPHICSLOT_L_RINGFINGER = 24;
GRAPHICSLOT_R_INDEXFINGER = 25; GRAPHICSLOT_R_INDEXFINGER = 25;
GRAPHICSLOT_L_INDEXFINGER = 26; GRAPHICSLOT_L_INDEXFINGER = 26;
function onEventStarted(player, actor, triggerName, equippedItem, param1, param2, param3, param4, param5, param6, param7, equipSlot, itemDBIds) function onEventStarted(player, actor, eventType, eventName, equippedItem, param1, param2, param3, param4, param5, param6, param7, equipSlot, itemDBIds)
equipSlot = equipSlot-1; equipSlot = equipSlot-1;
--Equip Item --Equip Item

View file

@ -1,4 +1,4 @@
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();

View file

@ -6,7 +6,7 @@ Handles moving items across item packages (IE: Taking loot)
--]] --]]
function onEventStarted(player, actor, triggerName, itemReference, targetPackage, sourcePackage, arg1, arg2, unknown, arg3, arg4, arg5, type9ItemIds) function onEventStarted(player, actor, eventType, eventName, itemReference, targetPackage, sourcePackage, arg1, arg2, unknown, arg3, arg4, arg5, type9ItemIds)
player:EndEvent(); player:EndEvent();

View file

@ -6,7 +6,7 @@ Handles giving an item to another party member.
--]] --]]
function onEventStarted(player, actor, triggerName, itemReference, targetPackage, sourcePackage, arg1, targetPlayer, arg2, arg3, arg4, arg5, type9ItemIds) function onEventStarted(player, actor, eventType, eventName, itemReference, targetPackage, sourcePackage, arg1, targetPlayer, arg2, arg3, arg4, arg5, type9ItemIds)
player:EndEvent(); player:EndEvent();

View file

@ -9,7 +9,7 @@ The param "itemDBIds" has the vars: item1 and item2.
--]] --]]
function onEventStarted(player, actor, triggerName, itemReference, targetPackage, sourcePackage, arg1, arg2, unknown, arg3, arg4, arg5, type9ItemIds) function onEventStarted(player, actor, eventType, eventName, itemReference, targetPackage, sourcePackage, arg1, arg2, unknown, arg3, arg4, arg5, type9ItemIds)
player:GetItemPackage(itemReference.itemPackage):RemoveItemAtSlot(itemReference.slot); player:GetItemPackage(itemReference.itemPackage):RemoveItemAtSlot(itemReference.slot);
player:EndEvent(); player:EndEvent();
end end

View file

@ -4,7 +4,7 @@ LinkshellAppointCommand Script
--]] --]]
function onEventStarted(player, actor, triggerName, linkshellName, memberName, rank) function onEventStarted(player, actor, eventType, eventName, linkshellName, memberName, rank)
GetWorldManager():RequestWorldLinkshellRankChange(player, linkshellName, memberName, rank); GetWorldManager():RequestWorldLinkshellRankChange(player, linkshellName, memberName, rank);
player:EndEvent(); player:EndEvent();

View file

@ -4,7 +4,7 @@ LinkshellChangeCommand Script
--]] --]]
function onEventStarted(player, actor, triggerName, linkshellName, arg1, arg2) function onEventStarted(player, actor, eventType, eventName, linkshellName, arg1, arg2)
if (linkshellName == nil) then if (linkshellName == nil) then
linkshellName = ""; linkshellName = "";

View file

@ -6,7 +6,7 @@ Handles what happens when you cancel an invite to a linkshell
--]] --]]
function onEventStarted(player, actor, triggerName, arg1, arg2, arg3, arg4, actorId) function onEventStarted(player, actor, eventType, eventName, arg1, arg2, arg3, arg4, actorId)
GetWorldManager():RequestWorldLinkshellCancelInvite(player); GetWorldManager():RequestWorldLinkshellCancelInvite(player);
player:EndEvent(); player:EndEvent();

View file

@ -6,7 +6,7 @@ Handles what happens when you invite a player to a linkshell
--]] --]]
function onEventStarted(player, actor, triggerName, linkshellName, arg1, arg2, arg3, actorId) function onEventStarted(player, actor, eventType, eventName, linkshellName, arg1, arg2, arg3, actorId)
GetWorldManager():RequestWorldLinkshellInviteMember(player, linkshellName, actorId); GetWorldManager():RequestWorldLinkshellInviteMember(player, linkshellName, actorId);
player:EndEvent(); player:EndEvent();

View file

@ -4,7 +4,7 @@ LinkshellKickCommand Script
--]] --]]
function onEventStarted(player, actor, triggerName, linkshellName, kickedName) function onEventStarted(player, actor, eventType, eventName, linkshellName, kickedName)
GetWorldManager():RequestWorldLinkshellKick(player, linkshellName, kickedName); GetWorldManager():RequestWorldLinkshellKick(player, linkshellName, kickedName);
player:EndEvent(); player:EndEvent();

View file

@ -4,7 +4,7 @@ LinkshellLeaveCommand Script
--]] --]]
function onEventStarted(player, actor, triggerName, linkshellName) function onEventStarted(player, actor, eventType, eventName, linkshellName)
GetWorldManager():RequestWorldLinkshellLeave(player, linkshellName); GetWorldManager():RequestWorldLinkshellLeave(player, linkshellName);
player:EndEvent(); player:EndEvent();

View file

@ -8,7 +8,7 @@ Handles post-dream events.
require ("global") require ("global")
function onEventStarted(player, actor, triggerName, dreamCode, innCode, narg1, narg2, bedActor) function onEventStarted(player, actor, eventType, eventName, dreamCode, innCode, narg1, narg2, bedActor)
--In Plain Sight --In Plain Sight
if (dreamCode == 1) then if (dreamCode == 1) then

View file

@ -12,7 +12,7 @@ eventLogoutFade()
require ("global") require ("global")
function onEventStarted(player, command, triggerName) function onEventStarted(player, command, eventType, eventName)
choice = callClientFunction(player, "delegateCommand", command, "eventConfirm"); choice = callClientFunction(player, "delegateCommand", command, "eventConfirm");

View file

@ -40,7 +40,7 @@ updateNegotiationWidget(player, gridIndex, key, itemIconId, pointValue, ?, ?) -
require ("global") require ("global")
function onEventStarted(player, commandactor, triggerName, arg1, arg2, arg3, arg4, arg5) function onEventStarted(player, commandactor, eventType, eventName, arg1, arg2, arg3, arg4, arg5)
negotiationJudge = GetStaticActor("NegotiationJudge"); negotiationJudge = GetStaticActor("NegotiationJudge");

View file

@ -6,7 +6,7 @@ Handles disbanding the party.
--]] --]]
function onEventStarted(player, actor, triggerName) function onEventStarted(player, actor, eventType, eventName)
worldMaster = GetWorldMaster(); worldMaster = GetWorldMaster();
if (player:IsPartyLeader()) then if (player:IsPartyLeader()) then

View file

@ -15,7 +15,7 @@ TextIds:
--]] --]]
function onEventStarted(player, actor, name) function onEventStarted(player, actor, eventType, eventName, name)
worldMaster = GetWorldMaster(); worldMaster = GetWorldMaster();
if (player:IsPartyLeader()) then if (player:IsPartyLeader()) then

View file

@ -6,7 +6,7 @@ Handles what happens when you invite
--]] --]]
function onEventStarted(player, actor, triggerName, name, arg1, arg2, arg3, actorId) function onEventStarted(player, actor, eventType, eventName, name, arg1, arg2, arg3, actorId)
if (name ~= nil) then if (name ~= nil) then
GetWorldManager():CreateInvitePartyGroup(player, name); GetWorldManager():CreateInvitePartyGroup(player, name);

View file

@ -15,7 +15,7 @@ TextIds:
--]] --]]
function onEventStarted(player, actor, triggerName, name, arg2, arg3, arg4, actorId) function onEventStarted(player, actor, eventType, eventName, name, arg2, arg3, arg4, actorId)
worldMaster = GetWorldMaster(); worldMaster = GetWorldMaster();
if (player:IsPartyLeader()) then if (player:IsPartyLeader()) then

View file

@ -6,7 +6,7 @@ Handles requesting to change party leader and various errors.
--]] --]]
function onEventStarted(player, actor, triggerName, name, arg2, arg3, arg4, actorId) function onEventStarted(player, actor, eventType, eventName, name, arg2, arg3, arg4, actorId)
worldMaster = GetWorldMaster(); worldMaster = GetWorldMaster();
if (player:IsPartyLeader()) then if (player:IsPartyLeader()) then

View file

@ -6,7 +6,7 @@ Handles leaving a party
--]] --]]
function onEventStarted(player, actor, triggerName) function onEventStarted(player, actor, eventType, eventName)
player:PartyLeave(name); player:PartyLeave(name);
player:EndEvent(); player:EndEvent();
end end

View file

@ -27,7 +27,7 @@ markers = { -- [id] = {overheadIcon, textIcon}
} }
function onEventStarted(player, actor, triggerName, commandValue, category, unk1, unk2, targetActor, unk3, unk4, unk5, unk6) function onEventStarted(player, actor, eventType, eventName, commandValue, category, unk1, unk2, targetActor, unk3, unk4, unk5, unk6)
workName = "charaWork.parameterTemp.targetInformation"; workName = "charaWork.parameterTemp.targetInformation";
uiFunc = "charaWork/stateForAll"; uiFunc = "charaWork/stateForAll";

View file

@ -1,5 +1,5 @@
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);

View file

@ -1,4 +1,4 @@
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();

View file

@ -3,7 +3,7 @@
--]] --]]
function onEventStarted(player, actor, questId) function onEventStarted(player, actor, eventType, eventName, questId)
player:SendDataPacket("requestedData", "activegl", 7, nil, nil, nil, nil, nil, nil, nil); player:SendDataPacket("requestedData", "activegl", 7, nil, nil, nil, nil, nil, nil, nil);
-- player:SendRequestedInfo("requestedData", "glHist", 10, 0x1D4F2, 1009, 12464, 11727, 12485, 12526); -- player:SendRequestedInfo("requestedData", "glHist", 10, 0x1D4F2, 1009, 12464, 11727, 12485, 12526);
end end

View file

@ -9,7 +9,7 @@ Finds the correct weaponskill subscript to fire when a weaponskill actor is acti
--]] --]]
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Ability(command.Id, targetActor); player.Ability(command.Id, targetActor);
player:endEvent(); player:endEvent();
end; end;

View file

@ -13,7 +13,7 @@ local attackMagicHandlers = {
} }
function onEventStarted(player, command, triggerName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8) function onEventStarted(player, command, eventType, eventName, arg1, arg2, arg3, arg4, targetActor, arg5, arg6, arg7, arg8)
player.Cast(command.Id, targetActor); player.Cast(command.Id, targetActor);
player:endEvent(); player:endEvent();
end; end;

View file

@ -24,7 +24,7 @@ reedit: Target has canceled their accept.
require ("global") require ("global")
function onEventStarted(player, actor, triggerName) function onEventStarted(player, actor, eventType, eventName)
callClientFunction(player, "delegateCommand", GetStaticActor("TradeExecuteCommand"), "processTradeCommandOpenTray"); callClientFunction(player, "delegateCommand", GetStaticActor("TradeExecuteCommand"), "processTradeCommandOpenTray");

View file

@ -6,7 +6,7 @@ Handles what happens a player cancels a trade
--]] --]]
function onEventStarted(player, actor, triggerName, commandId, result) function onEventStarted(player, actor, eventType, eventName, commandId, result)
GetWorldManager():CancelTrade(player); GetWorldManager():CancelTrade(player);
player:EndEvent(); player:EndEvent();

View file

@ -6,7 +6,7 @@ Handles what happens when you invite to trade
--]] --]]
function onEventStarted(player, actor, triggerName, name, arg1, arg2, arg3, actorId) function onEventStarted(player, actor, eventType, eventName, name, arg1, arg2, arg3, actorId)
local otherActor = nil; local otherActor = nil;

View file

@ -40,6 +40,7 @@ MESSAGE_TYPE_URGENT_MESSAGE = 28;
MESSAGE_TYPE_GENERAL_INFO = 29; MESSAGE_TYPE_GENERAL_INFO = 29;
MESSAGE_TYPE_SYSTEM = 32; MESSAGE_TYPE_SYSTEM = 32;
MESSAGE_TYPE_SYSTEM_ERROR = 33; MESSAGE_TYPE_SYSTEM_ERROR = 33;
MESSAGE_TYPE_NPC_LINKSHELL = 39;
-- INVENTORY -- INVENTORY
INVENTORY_NORMAL = 0x0000; --Max 0xC8 INVENTORY_NORMAL = 0x0000; --Max 0xC8

View file

@ -99,6 +99,7 @@ ECHO_EXIT_TRIGGER2 = 1090001;
CNTR_SEQ7_CUL = 1; CNTR_SEQ7_CUL = 1;
CNTR_SEQ7_MRD = 2; CNTR_SEQ7_MRD = 2;
CNTR_SEQ40_FSH = 3; CNTR_SEQ40_FSH = 3;
CNTR_LS_MSG = 4;
function onStart(player, quest) function onStart(player, quest)
quest:StartSequence(SEQ_000); quest:StartSequence(SEQ_000);
@ -164,10 +165,6 @@ function onStateChange(player, quest, sequence)
quest:SetENpc(ADVENTURER2); quest:SetENpc(ADVENTURER2);
quest:SetENpc(ADVENTURER3); quest:SetENpc(ADVENTURER3);
quest:SetENpc(ECHO_EXIT_TRIGGER, subseqMRD == 3 and QFLAG_MAP or QFLAG_NONE, false, subseqMRD == 3); quest:SetENpc(ECHO_EXIT_TRIGGER, subseqMRD == 3 and QFLAG_MAP or QFLAG_NONE, false, subseqMRD == 3);
if (subseqCUL == 1 and subseqMRD == 4) then
player:SetNpcLS(1, 1);
end
elseif (sequence == SEQ_035) then elseif (sequence == SEQ_035) then
quest:SetENpc(NNMULIKA, QFLAG_PLATE); quest:SetENpc(NNMULIKA, QFLAG_PLATE);
elseif (sequence == SEQ_040) then elseif (sequence == SEQ_040) then
@ -406,6 +403,9 @@ function seq007_onTalk(player, quest, npc, classId)
if (subseqCUL == 0) then if (subseqCUL == 0) then
callClientFunction(player, "delegateEvent", player, quest, "processEvent030"); callClientFunction(player, "delegateEvent", player, quest, "processEvent030");
data:IncCounter(CNTR_SEQ7_CUL); data:IncCounter(CNTR_SEQ7_CUL);
if (data:GetCounter(CNTR_SEQ7_CUL) == 1 and data:GetCounter(CNTR_SEQ7_MSK) = 4) then
seq007_endSequence(player, quest);
end
--give 1000g --give 1000g
else else
callClientFunction(player, "delegateEvent", player, quest, "processEvent030_2"); callClientFunction(player, "delegateEvent", player, quest, "processEvent030_2");
@ -448,6 +448,11 @@ function seq007_onTalk(player, quest, npc, classId)
player:EndEvent(); player:EndEvent();
end end
function seq007_endSequence(player, quest)
callClientFunction(player, "delegateEvent", player, quest, "processEvent033");
player:SetNpcLS(1, 1);
end
function seq080_085_onTalk(player, quest, npc, classId) function seq080_085_onTalk(player, quest, npc, classId)
if (classId == IOFA) then if (classId == IOFA) then
callClientFunction(player, "delegateEvent", player, quest, "processEvent630_2"); callClientFunction(player, "delegateEvent", player, quest, "processEvent630_2");
@ -484,6 +489,9 @@ function onPush(player, quest, npc)
elseif (classId == ECHO_EXIT_TRIGGER) then elseif (classId == ECHO_EXIT_TRIGGER) then
callClientFunction(player, "delegateEvent", player, quest, "processEvent060"); callClientFunction(player, "delegateEvent", player, quest, "processEvent060");
data:IncCounter(CNTR_SEQ7_MRD); data:IncCounter(CNTR_SEQ7_MRD);
if (data:GetCounter(CNTR_SEQ7_CUL) == 1 and data:GetCounter(CNTR_SEQ7_MSK) = 4) then
seq007_endSequence(player, quest);
end
player:EndEvent(); player:EndEvent();
quest:UpdateENPCs(); quest:UpdateENPCs();
GetWorldManager():WarpToPublicArea(player); GetWorldManager():WarpToPublicArea(player);
@ -509,7 +517,8 @@ function onPush(player, quest, npc)
callClientFunction(player, "delegateEvent", player, quest, "processEvent620"); callClientFunction(player, "delegateEvent", player, quest, "processEvent620");
-- Give 3000 gil -- Give 3000 gil
player:EndEvent(); player:EndEvent();
quest:StartSequence(SEQ_075); data:SetCounter(CNTR_LS_MSG, 0);
quest:StartSequence(SEQ_070);
end end
elseif (sequence == SEQ_085) then elseif (sequence == SEQ_085) then
if (classId == ECHO_EXIT_TRIGGER2) then if (classId == ECHO_EXIT_TRIGGER2) then
@ -634,6 +643,7 @@ end
function onNpcLS(player, quest, npcLSId) function onNpcLS(player, quest, npcLSId)
local sequence = quest:getSequence(); local sequence = quest:getSequence();
callClientFunction(player, "delegateEvent", player, quest, "processEvent625");
if (npcLSId == 1) then if (npcLSId == 1) then
player:SetNpcLS(1, 1); player:SetNpcLS(1, 1);
@ -646,9 +656,18 @@ function onNpcLS(player, quest, npcLSId)
player:SendGameMessageLocalizedDisplayName(quest, 82, 39, 1000015, nil); player:SendGameMessageLocalizedDisplayName(quest, 82, 39, 1000015, nil);
quest:StartSequence(SEQ_035); quest:StartSequence(SEQ_035);
elseif (sequence == SEQ_070) then elseif (sequence == SEQ_070) then
callClientFunction(player, "delegateEvent", player, quest, "processEvent625"); local lsStep = data:IncCounter(CNTR_LS_MSG);
player:EndEvent(); if (lsStep == 1) then
player:SendGameMessageLocalizedDisplayName(quest, 80, 39, 1000015, nil);
elseif (lsStep == 2) then
player:SendGameMessageLocalizedDisplayName(quest, 80, 39, 1000015, nil);
elseif (lsStep == 3) then
player:SendGameMessageLocalizedDisplayName(quest, 80, 39, 1000015, nil);
else
player:SendGameMessageLocalizedDisplayName(quest, 80, 39, 1000015, nil);
quest:StartSequence(SEQ_075); quest:StartSequence(SEQ_075);
end
player:EndEvent();
elseif (sequence == SEQ_090) then elseif (sequence == SEQ_090) then
callClientFunction(player, "delegateEvent", player, quest, "processEvent637"); callClientFunction(player, "delegateEvent", player, quest, "processEvent637");
player:EndEvent(); player:EndEvent();

View file

@ -168,8 +168,6 @@ function onNotice(player, quest, target)
quest:UpdateENPCs(); quest:UpdateENPCs();
end end
function seq000_onTalk(player, quest, npc, classId) function seq000_onTalk(player, quest, npc, classId)
if (classId == MOMODI) then if (classId == MOMODI) then