The plugins are very easy to make, I made a Hello World for a future tutorial with Chris a few days ago.
Printable View
The plugins are very easy to make, I made a Hello World for a future tutorial with Chris a few days ago.
Ah - I see. So this provides the pathfinder, database connection, etc and then a plugin will provide the habbo protocol depending on the version. That's quite smart and I await to see multi-client-version plugins working in the near future.
That's always good to hear!
I hate it! The IDs are very wrong. No body. No hair.
I have had to add to it just to log in.
Not quite :):
For starters, plugins provide the pathfinder. The pathfinder is set per user, not per room.
The main idea of plugins is to keep stuff that changes or is optional apart from what is the same in all clients (more or less).
Good Luck with this Cecer1
Thanks, it isn't easy when my computer is in the hall with nothing but a power cable and a wireless adapter. (My room is being redecorated.) But it is getting there.
Keep taking your sweet time with it man, in the end it'll be just that much sweeter! Looking forward to its debut, been following its progress since day 1, the last shockwave version is my favourite.
If you cba, can you upload some screenies of certain things to give us a better idea of what's done?
Hope your room turned out well.
Plugin Changes
Many hours of research.
More problems than I can remember.
One huge headache.
I have finally given up with the current plugin system.
(But it isn't as bad as it sounds)
Here are the changes to the planned plugin system:
- Plugins can no longer be stopped.
- To update/unload a plugin you have to restart IHI.
- IHI can't automatically tell which plugin called a method.
- Plugins can't have separate access. They all run as administrator.
- IHI requires administrator for the WebAdmin.
In other news
I now have my room back along with computer and a working mouse.
I'll start reforming the plugin system tonight and then resume work on the newer, simpler plugin format.
Cecer me and you need one of our discovering conversations again where you spend a hour explining to ne how somthing works, and once I understand it I immediatly figure out a solution.
Random Description
By default IHI doesn't block much at all.
Room rights default to enabled (though not shown in the client).
Room passwords/doorbells are not effective by default.
The way stuff is blocked is (as ever) with plugins.
Most events come in two flavours. PreAction and PostAction.
PreAction events fire before the action is performed (e.g. Moving furni).
PostAction events fire after the action has been performed.
Here is an example (not actual source code):
PHP Code:public override void Start()
{
// Register events
RoomDistributer.OnPreFurniMove += new FurniMoveEventHandler(MoveRightsEnforcer);
RoomDistributer.OnPostFurniMove += new FurniMoveEventHandler(MoveRightsReporter);
}
private void MoveRightsEnforcer(object source, FurniMoveEventArgs e)
{
Habbo Mover = (e.GetMover() as Habbo);
if(Mover == null)
return; // Not caused by a Habbo, no right check required.
// Example method, demonstration purposes only.
if(!Mover.SomeMethodToCheckRights())
{
// Mark it as cancelled
e.Cancel();
}
}
private void MoveRightsReporter(object source, FurniMoveEventArgs e)
{
if(e.IsCancelled())
{
// Furni hasn't moved
}
else
{
// Furni has moved.
}
}
Ah I understand completely Chris. I like the Post and Pre actions.
:D: