By completing this guide, you should be able to trigger Battle Arena event kill and build your own custom systems.
Stored Procedure: _OnBattleArenaKill
Parameters:
@CharID INT - Killer character ID
@CharName16 VARCHAR(64) - Killer character name
@DeadCharID INT - Dead character ID
@DeadCharName16 VARCHAR(64) - Dead character name
@ArenaType TINYINT - Battle Arena type
Let's send a text notification to the killer character using _Char_SendTextNotification to ensure that the trigger works fine for us.
USE [vPlus]
GO
/****** Object: StoredProcedure [dbo].[_OnBattleArenaKill] ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- =============================================
-- Author: <Author,,Name>
-- Create date: <Create Date,,>
-- Description: <Description,,>
-- =============================================
ALTER PROCEDURE [dbo].[_OnBattleArenaKill]
@CharID INT,
@CharName16 VARCHAR(64),
@DeadCharID INT,
@DeadCharName16 VARCHAR(64),
@ArenaType TINYINT
AS
BEGIN
SET NOCOUNT ON;
/*
This procedure is executed when a character kills another
character in the Battle Arena event.
@CharID represents the killer character ID.
@CharName16 represents the killer character name.
@DeadCharID represents the dead character ID.
@DeadCharName16 represents the dead character name.
@ArenaType:
0 = Random
1 = Party
2 = Guild
3 = Job
*/
--------- Your code starts here --------
EXEC _Char_SendTextNotification @CharID, 'You killed a player in the Battle Arena event', 1, 0, 0;
END