Sub Activity_Pause (UserClosed As Boolean)
If lGdx.IsInitialized Then lGdx.Pause
If cMap <> 0 Then nc.cMapDispose(cMap)
Activity.Finish
'ExitApplication
End Sub
Sub LG_Dispose
AM.dispose
Batch.dispose
Vector.dispose
DisposeFonts
End Sub
@ilan, The controls are now set to 4 centimeters wide, no matter the device or display.
Thanks... I'll try to figure it out...why r u doing it like this @@wonder? there MUST be a relation between sprite size and device you cannot set the same size to a 3.5" screen and a 10" screen!
just use % of the screen.width (or height) it doesnot matter but like this you will get the same size on all devices.
btw. the controls are now to big
Thanks... I'll try to figure it out...
Yep, exactly like this!!I'm thinking about little rectangles with a shaperenderer,
Dim x, y As Double
gl.glEnable(Gl.GL10_BLEND)
Gl.glBlendFunc(Gl.GL10_SRC_ALPHA, Gl.GL10_ONE_MINUS_SRC_ALPHA)
Camera.Update
vector.ProjectionMatrix = Camera.Combined
vector.Begin(vector.SHAPETYPE_Filled)
'Each particle must belong to an actor
For Each character As GameCharacter In CharacterList
For Each actor As Actor In character.actor
If actor.isParticlesActive Then
vector.Color = IfTrue(actor.particleColor1 <> actor.particleColor2 And frameCount mod 2 = 0, actor.particleColor1, actor.particleColor2)
For Each p As GameParticle In actor.particles
If p.active Then
x = cam.offsetX + p.x - actor.particleHalfSize
y = cam.offsetY + p.y - actor.particleHalfSize
vector.Rect(x, y, p.size, p.size)
End If
Next
'This function takes care of updating the velocity and position vectors, as well as deactivating any "outOfMap" particles
actor.ParticlesUpdate(LGStep)
End If
Next
Next
vector.end
Gl.glDisable(Gl.GL10_BLEND)