Jump to content

1 Screenshot

About This File

Description
A News npc that will let the players read news from the server stocked in sql. It can print colors and show an animated showevent to attract players if there's a new news.
Each news is separated in 2, the resume and more. Make a short version of your news and then explain it more. That way you have more chance to spread at least the important part of it to the players.

Installation
-Run this sql command

CREATE TABLE IF NOT EXISTS `z_custom_news` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `News` text NOT NULL,
  `Resume` text NOT NULL,
  `More` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

-Add news

-Edit the !!Modify  Lines

-Check if you want to edit anything in the OnInit.

-Load the npc (news.txt) and voila!

-The news are sql and to update in game, just make a gm talk to it, no need to reload it each time. Not making it checking each time someone talk to it (or each hour ect) make the npc less ressource consuming, but you can edit it and make the request everytime.

Information
-It does not make a lot of sql request, it only update when a gm talk to it and chose to update.

-It saves the highest news seen and print an event to attract the attention of the player, commenting all the !!Saving Mecanism!! lines removes it. It does not save which one you saw.

-You can add color using ^RRGGBB and adding new lines using # (editable)
 


What's New in Version 1.2.0   See changelog

Released

Automatically going to the news after updating as a gm. You don't need to reclick on the npc anymore to check the updated news.


×
×
  • Create New...