Thread: Event manager

Results 1 to 4 of 4
  1. #1 Event manager 
    Registered Member 0mg pwnage's Avatar
    Join Date
    May 2012
    Posts
    49
    Thanks given
    23
    Thanks received
    5
    Rep Power
    11
    [Only registered and activated users can see links. ]

    After doing this tutorial i get those errors:

    EventContainer.java:16: error: cannot find symbol
    private Event event;
    ^
    symbol: class Event
    location: class EventContainer
    EventContainer.java:33: error: cannot find symbol
    protected EventContainer(Event evt, int tick) {
    ^
    symbol: class Event
    location: class EventContainer
    EventManager.java:117: error: cannot find symbol
    public synchronized void addEvent(Event event, int tick) {
    ^
    symbol: class Event
    location: class EventManager
    3 errors

    anyone any idea how to fix this?
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  2. #2  
    Banned
    Join Date
    Jan 2014
    Posts
    596
    Thanks given
    91
    Thanks received
    60
    Discord
    View profile
    Rep Power
    0
    cannot find symbol means it can't find it that means you need to import
    Reply With Quote  
     

  3. #3  
    Registered Member 0mg pwnage's Avatar
    Join Date
    May 2012
    Posts
    49
    Thanks given
    23
    Thanks received
    5
    Rep Power
    11
    thx for quick reply. I forgot the Event.java
    All works fine now
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  4. #4  
    Banned Market Banned Market Banned


    Join Date
    Jan 2011
    Age
    23
    Posts
    3,115
    Thanks given
    1,198
    Thanks received
    1,479
    Rep Power
    0
    Quote Originally Posted by 0mg pwnage View Post
    thx for quick reply. I forgot the Event.java
    All works fine now
    The EventManager is like 7 years old now and isn't thread safe, use his newer one.

    Many people here have probably seen servers with my old "EventManager" code.

    Unfortunately there are several issues with the event manager:

    - Jagex has confirmed that all events run in a 600 millisecond cycle. The event manager does not enforce this and in fact events can be executed "out of phase" depending on how fast the server is. Therefore when using the event manager it is hard to keep the events timed perfectly.

    - In most cases people did not ensure the code they executed within the events was thread-safe. This was necessary because the events were called from a different thread from the main game logic processing thread. Failing to use concurrent data structures or synchronization led to issues such as corrupting packets (causing client disconnection) or other strange things.

    - The timing code could sometimes drift by several milliseconds due to use of the systemCurrentTimeMillis() method, which on some operating systems is only accurate to 10 milliseconds or so.

    - The whole "EventContainer" concept was borked and an abstract class should have been used instead.

    Therefore I have decided that the community really needs a better replacement which fixes all of these issues. So I decided to write this tutorial. I'm not going to explain why using the process() method is bad, if you want to find out then read the previous tutorial.
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Kinda full mining [Using Grahams event manager]
    By Cascade in forum Tutorials
    Replies: 26
    Last Post: 08-22-2009, 11:29 PM
  2. Graham's Event Manager
    By Mrquarterx in forum Snippets
    Replies: 25
    Last Post: 02-20-2009, 12:56 AM
  3. Using Grahams Event Manager in Combat.
    By DefNotVastico in forum Tutorials
    Replies: 10
    Last Post: 02-03-2009, 02:53 PM
  4. Event Manager help
    By Rabid Butterfly in forum Help
    Replies: 8
    Last Post: 02-01-2009, 05:46 PM
  5. Help Please Event Manager
    By xxt4nkxx in forum Help
    Replies: 6
    Last Post: 01-05-2009, 01:04 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •