💬NPC Examples
Copy-paste NPC scripts for Discord integration
Ready-to-use scripts. Replace YOUR_CHANNEL_ID with your Discord channel ID.
Event Announcements
Announce events to Discord automatically:
- script EventAnnouncer -1,{
OnHour12:
ragnascript("[action: npc_message][name: Event Manager][message: Daily Hunt is now active!][channel: YOUR_CHANNEL_ID]");
announce "Daily Hunt event is now active!", bc_all;
end;
}Player Shoutbox
Let players send messages to Discord:
prontera,155,180,4 script Discord Shout 100,{
mes "[Discord]";
mes "Send a message to Discord?";
if (select("Yes:No") == 1) {
input .@msg$;
if (.@msg$ != "") {
ragnascript("[action: message][channel: YOUR_CHANNEL_ID][name: " + strcharinfo(0) + "][message: " + .@msg$ + "][account_id: " + getcharid(3) + "][char_id: " + getcharid(0) + "]");
mes "Sent!";
}
}
close;
}New Player Alerts
Notify staff when new players join:
Server Maintenance Notice
WoE Status
Anti-Bot Alerts
Notify staff when suspicious activity is detected:
You can also trigger alerts from your existing anti-bot systems:
Tips
NPC messages - Use npc_message action for server-generated announcements. Only requires name, message, and channel.
Rate limiting - Add cooldowns to player-triggered scripts to prevent spam:
Need the basics? See RagnaScript Overview.
Last updated
