|
@@ -486,6 +486,7 @@ public class ARActivity extends RendererActivity
|
|
|
public void onClickPickUp(View v)
|
|
|
{
|
|
|
synchronized (mUpdate) {mUpdate=false;}
|
|
|
+ Stage s = mGame.getCurrentStageObj();
|
|
|
ArrayList<Resource> res = null;
|
|
|
boolean stageFinished = mGame.pickResource();
|
|
|
boolean finished = false;
|
|
@@ -504,7 +505,6 @@ public class ARActivity extends RendererActivity
|
|
|
|
|
|
if(stageFinished)
|
|
|
{
|
|
|
- Stage s = mGame.getCurrentStageObj();
|
|
|
Resource stageRes = s.getResource();
|
|
|
|
|
|
if(finished)
|
|
@@ -512,13 +512,20 @@ public class ARActivity extends RendererActivity
|
|
|
Intent intent2 = new Intent(this, EndActivity.class);
|
|
|
startActivity(intent2);
|
|
|
}
|
|
|
+ System.out.println("Ressource: '"+s.getResourceName()+"' : "+!s.getResourceName().isEmpty());
|
|
|
+ if(!s.getResourceName().isEmpty())
|
|
|
+ {
|
|
|
+ Intent intent = new Intent(this, ViewerActivity.class);
|
|
|
+ intent.putExtra("resource", stageRes);
|
|
|
+ startActivity(intent);
|
|
|
+ }
|
|
|
|
|
|
- Intent intent = new Intent(this, ViewerActivity.class);
|
|
|
- intent.putExtra("resource", stageRes );
|
|
|
- startActivity(intent);
|
|
|
-
|
|
|
- Intent intent2 = new Intent(this, TransferActivity.class);
|
|
|
- startActivity(intent2);
|
|
|
+ System.out.println("Transition: '"+s.isTransition());
|
|
|
+ if(s.isTransition())
|
|
|
+ {
|
|
|
+ Intent intent2 = new Intent(this, TransferActivity.class);
|
|
|
+ startActivity(intent2);
|
|
|
+ }
|
|
|
}
|
|
|
for(int i=0; i<res.size(); i++)
|
|
|
{
|