Re: news file date

From: Patrick J. Dughi (dughi@IMAXX.NET)
Date: 01/25/98


> I'm trying to implement a warning system for players, which will show
> something like "You have news waiting" at login if date of news file
> differs from date stored in char's variable.
> But I don't know how to work with file date using ANSI C functions only. :(
> Can anyone help me? Basically I have two questions:
> How can I get date of creation of file?
> In which type of variable it can be stored?
>

        Though I'll not give you step by step how-to's, you might want to
look at how the char's last time in is saved.  Then, just update it
instead of on login, only when the news file is read. The code for the
date functions are already there, just shuffle it around, and add a time_t
struct (or whatever) to your player structure.

                                        PjD


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/15/00 PST