package com.tacktic.inbudget;

import com.badlogic.gdx.Game;
import com.badlogic.gdx.graphics.g2d.BitmapFont;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;

public class InBudget extends Game {
    private Resources resources;
    private SpriteBatch batch;
    private BitmapFont font;

    public Resources resources() {
        return resources;
    }

    public SpriteBatch batch() {
        return batch;
    }

    public BitmapFont font() {
        return font;
    }

    @Override
    public void create() {
        resources = new Resources();
        batch = new SpriteBatch();
        font = new BitmapFont();
        this.setScreen(new MainMenuScreen(this));
    }

    @Override
    public void render() {
        super.render();
    }

    @Override
    public void dispose() {
        resources.dispose();
        batch.dispose();
        font.dispose();
    }
}

@@ -152,16 +152,226 @@
 teBatch;
+%0Aimport com.typesafe.config.Config;%0Aimport com.typesafe.config.ConfigFactory;%0Aimport io.sphere.sdk.client.JavaClient;%0Aimport io.sphere.sdk.client.JavaClientImpl;%0A%0Aimport java.util.HashMap;%0Aimport java.util.Map;
 %0A%0Apublic
@@ -493,16 +493,47 @@
 nt font;
+%0A    private JavaClient sphere;
 %0A%0A    pu
@@ -707,32 +707,95 @@
 rn font;%0A    %7D%0A%0A
+    public JavaClient sphere() %7B%0A        return sphere;%0A    %7D%0A%0A
     @Override%0A  
@@ -920,24 +920,63 @@
 tmapFont();%0A
+        sphere = createSphereClient();%0A
         this
@@ -1180,32 +1180,32 @@
 atch.dispose();%0A
-
         font.dis
@@ -1217,11 +1217,600 @@
 );%0A    %7D
+%0A%0A    private JavaClient createSphereClient() %7B%0A        final Map%3CString, Object%3E values = new HashMap%3CString, Object%3E();%0A        values.put(%22sphere.auth%22, %22https://auth.sphere.io%22);%0A        values.put(%22sphere.core%22, %22https://api.sphere.io%22);%0A        values.put(%22sphere.project%22, System.getenv(%22IN_BUDGET_PROJECT%22));%0A        values.put(%22sphere.clientId%22, System.getenv(%22IN_BUDGET_CLIENT_ID%22));%0A        values.put(%22sphere.clientSecret%22, System.getenv(%22IN_BUDGET_CLIENT_SECRET%22));%0A        final Config config = ConfigFactory.parseMap(values);%0A        return new JavaClientImpl(config);%0A    %7D
 %0A%7D%0A

Connect with SPHERE.