Language: 
To browser these website, it's necessary to store cookies on your computer.
The cookies contain no personal information, they are required for program control.
  the storage of cookies while browsing this website, on Login and Register.

Author Topic:  PA  (Read 953 times)

0 Members and 1 Guest are viewing this topic.

smacky

PA

« on: 15, February 2019, 18:09:12 »
Hello :),

I'm still alive. And it seems so is Dai, which is good.  Don't worry though, I'm not likely to return full time

But I do have loads of unreleased features lying around. Most are unfinished or too involved, but here's one which should work.

I've put it in the stream PA. PA is a load of server/src changes which add a new default channel, PA (shortcut p). This is the Player Announcements/Activity channel. Whenever a player logins, levels up, dies, or logouts, the appropriate script from maps/lua/player is run. Basically these send a sarky message to PA (logout.lua does more important stuff too. It replaces event_logout.lua). The idea is to make players a bit more of a community.

ISTR back in B3 when the server announced deaths we had abusers who would rapidly suicide over and over. It should be possible to detect/prevent/punish this in Lua if it is  a problem.

It should be fine to message PA from normal object sccripts (is there a player:GetPrivacy() method)?). Foexample from a death script for a really major boss or a pickup/apply script for a prize object. TODO: Add a 5th player event to run a script on (select?) quest completion.

This also gets rid of the automatic SCRIPT_FIX_* flags. These were (almost?) always pointless and misused. But if you find a misbehaving  script just try eg, player:Fix() at the end.

For reasons too lengthy to detail here (comments in code). I added a KNOWLEDGE script trigger. This is an AI thing. Used to be a TRIGGER hack/abuse. But I'm pretty sure it was never used anyway.

I wrote this almost 3 years ago (8024). Worked then. I merged it to trunk head yesterday but have not even compiled it. Hopefully it still works. I got rid of a load of redundant plugin code (the never used/liked global event stuff from CF). Anyway, it should be easy to review and add to trunk/main if it's wanted.

Fingers crossed. Back in a few days.

myths

« Reply #1 on: 15, February 2019, 18:56:44 »
Very glad to hear from you Smacky and we all hope you return soon.
A quick question....I understand PA as you've described it.
If I or another player is in /Privacy will this still do what you listed above?
Or is /privacy an auto block to this?
My retirement approaches...like the Grim Reaper

_people_

« Reply #2 on: 16, February 2019, 04:18:26 »
Hi Smacky! :)

Good work on this PA stuff. Back in late 2017 I made a server feature which would deliver help files in a SENTInce GUI generated from Lua rather than a text dump. The code I wrote to execute scripts from the server vice maps is much more ugly, and yours looks way more robust. So this will definitely be good to replace what I had.

Myths, looking at the code it appears that his scripts do respect privacy mode.
-- _people_ :)

smacky

« Reply #3 on: 16, February 2019, 14:50:43 »
I lied about back in a few days. This project is addictive.

@myths: The scripts all know about privacy and are all written to respect this.

@_people_: Yes I just found your help code. :) Broke PA. I think I fixed it in the stream.

smacky

« Reply #4 on: 22, February 2019, 17:20:38 »
I  think it's ready now. I added also a finished quest event and a found one/special drop event (note random drops are different and not covered (ATM) -- ISTR some issue in this area in the past. not sure what the current status is).

I also fixed repeatable  quests (99% sure)..

_people_

« Reply #5 on: 02, March 2022, 22:47:45 »
I've just merged this to trunk. While I think I saw a few mentions of unfinished functionality in the code, testing indicates it's stable regardless. Future changes can be made directly in trunk.

These improvements give mappers/scripters and developers a lot of flexibility in how we can interact with the player. For example, the Random Dungeons can now reset the player's current progress tier if they've died in a random dungeon.

Players: There are quite a few core system changes in here. For the most part it's invisible to players, but since core functionality (gaining/losing EXP, dying, logging in/out) is affected there may be some obvious or well-hidden bugs. Keep an eye out once these changes are on public servers.
-- _people_ :)

Tags: