Forums WoW Modding Support Archives Azerothcore Discord Archives [DiscordArchive] Show the whole function?

[DiscordArchive] Show the whole function?

[DiscordArchive] Show the whole function?

Pages (11): Previous 1 2 3 4 5 11 Next  
rektbyfaith
Administrator
0
09-27-2023, 01:43 PM
#21
Archived author: Trojan • Posted: 2023-09-27T13:43:17.803000+00:00
Original source

```lua
local function PlayerDeath(event, player, killer)
print(player:GetGuid())
if player:HasItem(666, 1) then
-- Get Player Information
local playerGUID = player:GetGUIDLow()
local playerName = player:GetName()
local playerLevel = player:GetLevel()

-- Check if the player is in the "HardCore" guild
local guild = player:GetGuild()
if guild and guild:GetName() == "HardCoded" then
guildBig GrineleteMember(player, false)
SendWorldMessage("|cFFffffffHardcore|r : |cFF007bf6" .. playerName .. " was removed from the Hardcore Guild!|r")
end

local players = GetPlayersInWorld()
local killerName = ""
if killer then
killerName = killer:GetName()
end

-- Broadcast Message to other players in the world
for _, p in ipairs(players) do
p:SendBroadcastMessage("|cFFffffffHardcore|r : |cFFffffffUser |cFF00ff00" .. playerName .. "|r |cFFffffffwas killed by |cFF00ff00" .. killerName .. "|r - |cFFffffffLevel " .. playerLevel .. "")
p:SendAreaTriggerMessage("|cFFffffffHardcore|r : |cFFffffffUser |cFF00ff00" .. playerName .. "|r |cFFffffffwas killed by |cFF00ff00" .. killerName .. "|r - |cFFffffffLevel " .. playerLevel .. "")
end
local input_HC_Dead = "INSERT INTO hc_dead_log (username, level, killer, date, result, guid) VALUES ('" .. player:GetName() .. "', '" .. player:GetLevel() .. "', '" .. killer:GetName() .. "', NOW(), 'DEAD', '" ..playerGUID.."')"
AuthDBExecute(input_HC_Dead)
-- Remove Hardcore Item from player
player:RemoveItem(666, 1)
end
end

RegisterPlayerEvent(6, PlayerDeath)
```
rektbyfaith
09-27-2023, 01:43 PM #21

Archived author: Trojan • Posted: 2023-09-27T13:43:17.803000+00:00
Original source

```lua
local function PlayerDeath(event, player, killer)
print(player:GetGuid())
if player:HasItem(666, 1) then
-- Get Player Information
local playerGUID = player:GetGUIDLow()
local playerName = player:GetName()
local playerLevel = player:GetLevel()

-- Check if the player is in the "HardCore" guild
local guild = player:GetGuild()
if guild and guild:GetName() == "HardCoded" then
guildBig GrineleteMember(player, false)
SendWorldMessage("|cFFffffffHardcore|r : |cFF007bf6" .. playerName .. " was removed from the Hardcore Guild!|r")
end

local players = GetPlayersInWorld()
local killerName = ""
if killer then
killerName = killer:GetName()
end

-- Broadcast Message to other players in the world
for _, p in ipairs(players) do
p:SendBroadcastMessage("|cFFffffffHardcore|r : |cFFffffffUser |cFF00ff00" .. playerName .. "|r |cFFffffffwas killed by |cFF00ff00" .. killerName .. "|r - |cFFffffffLevel " .. playerLevel .. "")
p:SendAreaTriggerMessage("|cFFffffffHardcore|r : |cFFffffffUser |cFF00ff00" .. playerName .. "|r |cFFffffffwas killed by |cFF00ff00" .. killerName .. "|r - |cFFffffffLevel " .. playerLevel .. "")
end
local input_HC_Dead = "INSERT INTO hc_dead_log (username, level, killer, date, result, guid) VALUES ('" .. player:GetName() .. "', '" .. player:GetLevel() .. "', '" .. killer:GetName() .. "', NOW(), 'DEAD', '" ..playerGUID.."')"
AuthDBExecute(input_HC_Dead)
-- Remove Hardcore Item from player
player:RemoveItem(666, 1)
end
end

RegisterPlayerEvent(6, PlayerDeath)
```

rektbyfaith
Administrator
0
09-27-2023, 01:43 PM
#22
Archived author: Honey • Posted: 2023-09-27T13:43:43.031000+00:00
Original source

PLAYER_EVENT_ON_KILL_PLAYER = 6, // (event, killer, killed)
rektbyfaith
09-27-2023, 01:43 PM #22

Archived author: Honey • Posted: 2023-09-27T13:43:43.031000+00:00
Original source

PLAYER_EVENT_ON_KILL_PLAYER = 6, // (event, killer, killed)

rektbyfaith
Administrator
0
09-27-2023, 01:43 PM
#23
Archived author: Foe • Posted: 2023-09-27T13:43:51.301000+00:00
Original source

That's whenever a player kills another player
rektbyfaith
09-27-2023, 01:43 PM #23

Archived author: Foe • Posted: 2023-09-27T13:43:51.301000+00:00
Original source

That's whenever a player kills another player

rektbyfaith
Administrator
0
09-27-2023, 01:43 PM
#24
Archived author: Trojan • Posted: 2023-09-27T13:43:53.090000+00:00
Original source

aaaah DAMN
rektbyfaith
09-27-2023, 01:43 PM #24

Archived author: Trojan • Posted: 2023-09-27T13:43:53.090000+00:00
Original source

aaaah DAMN

rektbyfaith
Administrator
0
09-27-2023, 01:44 PM
#25
Archived author: Trojan • Posted: 2023-09-27T13:44:03.139000+00:00
Original source

why it gets triggered then
rektbyfaith
09-27-2023, 01:44 PM #25

Archived author: Trojan • Posted: 2023-09-27T13:44:03.139000+00:00
Original source

why it gets triggered then

rektbyfaith
Administrator
0
09-27-2023, 01:44 PM
#26
Archived author: Trojan • Posted: 2023-09-27T13:44:04.722000+00:00
Original source

wtf
rektbyfaith
09-27-2023, 01:44 PM #26

Archived author: Trojan • Posted: 2023-09-27T13:44:04.722000+00:00
Original source

wtf

rektbyfaith
Administrator
0
09-27-2023, 01:44 PM
#27
Archived author: Foe • Posted: 2023-09-27T13:44:23.346000+00:00
Original source

Environmental deaths are triggered by the same event, but killer is nil
rektbyfaith
09-27-2023, 01:44 PM #27

Archived author: Foe • Posted: 2023-09-27T13:44:23.346000+00:00
Original source

Environmental deaths are triggered by the same event, but killer is nil

rektbyfaith
Administrator
0
09-27-2023, 01:44 PM
#28
Archived author: Trojan • Posted: 2023-09-27T13:44:27.224000+00:00
Original source

when its the wrong event why it gets triggered when i get killed by a mob
rektbyfaith
09-27-2023, 01:44 PM #28

Archived author: Trojan • Posted: 2023-09-27T13:44:27.224000+00:00
Original source

when its the wrong event why it gets triggered when i get killed by a mob

rektbyfaith
Administrator
0
09-27-2023, 01:44 PM
#29
Archived author: Foe • Posted: 2023-09-27T13:44:40.063000+00:00
Original source

It shouldn't trigger when you get killed by a creature
rektbyfaith
09-27-2023, 01:44 PM #29

Archived author: Foe • Posted: 2023-09-27T13:44:40.063000+00:00
Original source

It shouldn't trigger when you get killed by a creature

rektbyfaith
Administrator
0
09-27-2023, 01:44 PM
#30
Archived author: Trojan • Posted: 2023-09-27T13:44:48.617000+00:00
Original source

yes
rektbyfaith
09-27-2023, 01:44 PM #30

Archived author: Trojan • Posted: 2023-09-27T13:44:48.617000+00:00
Original source

yes

Pages (11): Previous 1 2 3 4 5 11 Next  
Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)