Author Topic: SmartCursor class  (Read 4391 times)

Offline Wipe

  • Rotator
  • Random is god
SmartCursor class
« on: July 20, 2013, 08:09:40 pm »
SmartCursor is a small class for client-side scripts, allowing to avoid unnecessary clicking when using various items. Instead of putting "tool" (like hatchet) in active slot, manually changing its mode to "use on" and finally clicking on resource (like tree), all that is done with single click. Tool required is searched in specified slot(s), and automagically used by calling SetChosenActions() function.

Additionally, when hovering usuable item, player is able to see what action will be performed and/or graphic of tool which is going to be used. Both are prepared to be easily configurable, so if server developer allows that, options could be changed by players via config file, or using ingame options screen.

By making it as a class, what's major difference between this and original version (see below), feature become a little more flexible, and - i hope! - easier to use, what was the main goal.

Source and full documentation can be found here:
https://github.com/wipe2238/fonline-misc/tree/master/smartcursor


Based on FOnline: 2238 script (by JovankaB)
http://fodev.net/forum/index.php/topic,28748.msg248106.html#msg248106
https://github.com/rotators/fo2238/blob/master/Server/scripts/client_smart_cursor.fos
« Last Edit: July 20, 2013, 08:23:48 pm by Wipe »
Games are meant to be created, not played...