So this is great news for people developing games using Ryzom Core but it is also pretty awesome news for Ryzom players with development skills. The Ryzom API that is available to players for development of external applications is pretty robust but doesn't provide a wealth of low-level access and does not embed into the game the same way WebIG does.
Now Ryzom players have the ability to create and contribute in-game applications!
About Ryzom API and WebIG
The Ryzom API has two main components - a server side website and client library. The server side component is what was just released. The Ryzom API allows third-party developers to develop their own applications using a simple ReST-style web service. The client API provides a PHP interface for web developers.
The Ryzom WebIG (Web In Game) system provides the basic framework for providing rapid functional development in Ryzom Core without the need to modify the client and distribute patches. The WebIG framework is a powerful way to add a very large amount of functionality very quickly. It also provides a dual purpose platform as most WebIG apps can also be accessed via the web. This allows game developers to minimize the amount of development needed for applications
- See the Ryzom API site for more information
- See the source code.
Configuration and Setup
The set up should be pretty straight forward. You will need to rename the config.php.default configuration files to config.php in their respective locations:
- code/web/app/config.php.default
- code/web/api/common/config.php.default
- code/web/api/server/config.php.default
- code/web/api/client/config.php.default
For example to the demo app app_test you'd create a new app_test database with a table called test with two columns: id and num_access. See this code for an example:
$db = ryDB::getInstance(APP_NAME);
$db->setDbDefs('test', array('id' => SQL_DEF_INT, 'num_access' => SQL_DEF_INT));
$db->update('test', array('num_access' => ++$num_access['num_access']), array('id' => $user['id']));
Getting Started
There's already a ton of information on the Ryzom API site for using the API and a number of great example applications created by Ryzom players available on places such as Github. Check out the contest submissions, there's a lot of great code and great ideas there!
Getting started writing a new WebIG app is pretty simple too. You'll need to copy app_test and then add your new app_whatever to code/web/app/lang.php and code/web/app/index.php so that the WebIG framework knows about your application. If your application uses a database you will need to create the new database, using your app name, using the host/user/pass specified in the RYAPI_WEBDB_* configuration variables.
Feel free to join us on irc.freenode.net in the channel #ryzom for more information or if you need help!
Getting started writing a new WebIG app is pretty simple too. You'll need to copy app_test and then add your new app_whatever to code/web/app/lang.php and code/web/app/index.php so that the WebIG framework knows about your application. If your application uses a database you will need to create the new database, using your app name, using the host/user/pass specified in the RYAPI_WEBDB_* configuration variables.
Feel free to join us on irc.freenode.net in the channel #ryzom for more information or if you need help!
This comment has been removed by a blog administrator.
ReplyDelete