Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

Policy to auto announce

Newbie Spellweaver
Joined
Nov 5, 2019
Messages
59
Reaction score
1
Hello all,

First I'd like to apologize if this has been asked before in the past, I wasn't ready to spend hours searching after finally finding what I wanted to find in the aipolicy.data file.

I've got a question about adding a custom policy to the file that announces when an event is about to happen. More specifically, I'd really like to know how the time an announcement is made in the file works.

For example the Santa Spam had happened three times a day, but I can't find the actual time frame inside the aipolicy file. How is all that really determined and how is it possible to add my own policy to the file to let's say, announce that an event will start in x minutes and to get ready and gather at x coordinates?

I'd love any response and sorry if it makes little to no sense. My brain doesn't seem to work as much lately. Lack of sleep and all.

Take care and stay safe!

Wasp
 
Joined
Jun 10, 2012
Messages
557
Reaction score
131
Hello all,

First I'd like to apologize if this has been asked before in the past, I wasn't ready to spend hours searching after finally finding what I wanted to find in the aipolicy.data file.

I've got a question about adding a custom policy to the file that announces when an event is about to happen. More specifically, I'd really like to know how the time an announcement is made in the file works.

For example the Santa Spam had happened three times a day, but I can't find the actual time frame inside the aipolicy file. How is all that really determined and how is it possible to add my own policy to the file to let's say, announce that an event will start in x minutes and to get ready and gather at x coordinates?

I'd love any response and sorry if it makes little to no sense. My brain doesn't seem to work as much lately. Lack of sleep and all.

Take care and stay safe!

Wasp

I think you can create a timer along with a broadcast message in aipolicy.data
 
Upvote 0
Newbie Spellweaver
Joined
Nov 5, 2019
Messages
59
Reaction score
1
I think you can create a timer along with a broadcast message in aipolicy.data


Thanks for a reply.

I am confused with this part... I will use the Santa spam as the example again.

It happens three times a day and that somewhat makes sense in the aipolicy file. But when looking at it, this is what I see and also what confuses me.

6U4psw8 - Policy to auto announce - RaGEZONE Forums

What exactly does the "Period 3" mean? That is what I am somewhat confused about.

Where does it take the time from the game so that it can send the broadcast within the "[2] talk (Version1)"? It's something that I wish I had somewhat of a little guide for haha.

The spam happened three times a day like stated, one of those times was at 18:00 server time. But the control on the map file has no time on it itself, so that was somewhat of a dead end for me.. otherwise that'd have made sense.

Thanks again for the reply, I hope you know what I can do with that. If not, I'll just have to go and create 500,000 different cron files xD (not really that many.... o.o)
 

Attachments

You must be registered for see attachments list
Upvote 0
Newbie Spellweaver
Joined
Aug 1, 2016
Messages
54
Reaction score
22
Period 3 is time is seconds, so here it's 3 seconds. Check the other triggers, there is TimeCome(x), x is the timer ID. So if timer finishes it runs that trigger, and the trigger writes the text. Counter is the amount of times the timer runs.
Timer starts from the moment the mob spawns. So if you spawn mob at 18:00 and timer period is 600, and at TimeCome it writes message, it will write message at 18:10, 18:20, 18:30 etc.
If you want message to be written at certain server time, then set mob to spawn at that time in NPCgen and attach an AiPolicy id where it writes text at !hpless(0.1), and don't forget to set close for the mob spawn, either in NPCgen with Autostop Delay or have AiPolicy close it with Active_Controller. Or use cron.
 
Last edited:
Upvote 0
Back
Top