You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 18, 2025. It is now read-only.
AlexTape edited this page Jul 1, 2015
·
3 revisions
Getting started with your JavaFX Application
After you set the UniBoxClient.jar and UniBoxCore.jar as required dependencies of your project, your are able to set it up to suit your needs.
First of all you have to set your username and password together with the IP address of
the UniBoxServer instance. To be flexible, the API will provide different methods
for that task to fit your needs.
You can pass your credentials as parameters as follows:
java -jar YourGame.jar <ip> <user> <password>
If you prefer that way, simply add the following calls to your main():
If you prefer a more static way you can place these methods in your start() method as well:
public final void start(final Stage primaryStage) {
// init credentials
ClientProvider.setIp("192.168.0.150");
ClientProvider.setUsername("user");
ClientProvider.setPassword("password");
// ...
}
After the credentials and the IP have been set, you can call the login routine to register your
application to the backend service.
ClientProvider.login();
Now you have a valid cookie to talk to the backend workers via an authorized channel.
To start the main loop of the Client API, you have to connect the local workers/threads
of your application with the backend.