haseeb-heaven / Openplanet-Plugin-Libs

This repo consists list of Helper libraries for Openplanet plugins written in AngelScripts, it contains mostly Utilities,UI,Time libraries which you can include in your Scripts and write plugins easily.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Openplanet-Plugin-Libs

This repo consists list of Helper libraries for Openplanet plugins written in AngelScripts, it contains Utilities for both OpenPlanet Api and TrackMania 2020 Api which you can include in your Scripts and write plugins easily.

Openplanet API Information.

Utils OpUtils.as is utilities for different Api like Core,Time,Net,Meta,Json,Net and more this provide helper methods to interact with Api's safe and easily.

How to Access Api Helper methods.

To access Api's helper methods check OpenPlanet Api Docs and see its file structure.
If you wish to access Time Api helper methods then write
OpUtils::Api-Name::HelperMethod()
example : auto sysTime = OpUtils::Time::GetSystemTime();

List of Available Helper Api's.

  • Time Api - Date and Time helper methods.
  • Net Api - Network and Sockets helper methods.
  • UI Api - ImGui helper methods.
  • Meta Api - Plugin Scripts helper methods.

Openplanet API Examples.

Plugin_OpUtilsDemo.as contains examples of using this Api.

TrackMania 2020 API Information.

Utils TmUtils.as is utilities for different Api like Core,Time,Net,Meta,Json,Net and more this provide helper methods to interact with Api's safe and easily.

How to Access Api Helper methods.

To access Api's helper methods check TrackMania 2020 Api Docs and see its file structure. If you wish to access Game Api helper methods then write
TmUtils::Api-Name::HelperMethod()
example : auto rootMap = TmUtils::Game::GetRootMap();

And same goes with other Api's like if you wish to access Shootmania then write.
auto player = TmUtils::ShootMania::GetActivePlayer();

List of Available Helper Api's.

TrackMania 2020 API Examples.

Plugin_TmUtilsDemo.as contains examples of using this Api.

Logger library Information.

Library Logger.as is the logger library with trace,warn,err debugging levels.

List of Public Methods.

  • SetPluginName()/GetPluginName() - Set or gets your plugin name.
  • EnableLogs() - Enable or disable logs. This property set to True by default=Enabled
  • AddLogInfo() - Adds log message as information on console.
  • AddLogTrace() - Adds log message as trace on console.
  • AddLogWarning() - Adds log message as warning on console.
  • AddLogError() - Adds log message as error on console.

Features.

  • Time stamp - Ability to add time stamps on logs.
  • Automatic detection - Ability to automatically detect Plugin name from Meta.
  • Toggle Logs - Ability to toggle logs on/off at any given point.
  • Plugin Name - Ability to add Plugin name on console to distinguish from other logs easily.

Examples.

Folder examples contains various examples of TrackMania and OpenPlanet Utils.

Plugin on Openplanet

This library available as Plguin on Openplanet as well.

Logger Demo output. Logger_Demo

Contributing

If you wish to contribute to this project then please do PR request and maintain the same strucute of Api directories.

VERSION INFO :
Utilities Version 1.0 Dated : 12/22/2021.

CHANGE LOGS FOR V 1.0
[+] Added Utils for Openplanet and TrackMania 2020.
[+] Added Examples for both Utils in examples folder.
[+] Updated Logger library.

written and maintained by Haseeb Heaven (haseebmir.hm@gmail.com)

About

This repo consists list of Helper libraries for Openplanet plugins written in AngelScripts, it contains mostly Utilities,UI,Time libraries which you can include in your Scripts and write plugins easily.

License:GNU General Public License v3.0


Languages

Language:AngelScript 100.0%