Updated Biniax2 and translations
This commit is contained in:
@@ -103,7 +103,7 @@
|
||||
<string name="rightclick_key">Физическая кнопка</string>
|
||||
<string name="pointandclick_showcreenunderfinger2">Наэкранная лупа</string>
|
||||
<string name="video">Настройки видео</string>
|
||||
<string name="video_smooth">Сгладить видео</string>
|
||||
<string name="video_smooth">Линейное сглаживание видео</string>
|
||||
<string name="accel_veryslow">Очень медленно</string>
|
||||
<string name="leftclick_timeout">Нажатие с задержкой</string>
|
||||
<string name="leftclick_tap">Быстрое нажатие</string>
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
<string name="rightclick_key">Фізична кнопка</string>
|
||||
<string name="pointandclick_showcreenunderfinger2">Наекранна лупа</string>
|
||||
<string name="video">Налаштування відео</string>
|
||||
<string name="video_smooth">Згладити відео</string>
|
||||
<string name="video_smooth">Лінійне сглажування відео</string>
|
||||
<string name="accel_veryslow">Дуже повільно</string>
|
||||
<string name="leftclick_timeout">Натискання з затримкою</string>
|
||||
<string name="leftclick_tap">Швидке натискання</string>
|
||||
|
||||
@@ -141,7 +141,7 @@
|
||||
<string name="calibrate_touchscreen_touch">Touch all edges of the screen, press BACK when done</string>
|
||||
|
||||
<string name="video">Video settings</string>
|
||||
<string name="video_smooth">Smooth the video</string>
|
||||
<string name="video_smooth">Linear video filtering</string>
|
||||
<string name="video_separatethread">Separate thread for video, will increase FPS on some devices</string>
|
||||
|
||||
<string name="text_edit_click_here">Tap to start typing, press Back when done</string>
|
||||
|
||||
@@ -4,8 +4,8 @@ LibSdlVersion=1.2
|
||||
AppName="Biniax2"
|
||||
AppFullName=com.biniax.sdl
|
||||
ScreenOrientation=h
|
||||
InhibitSuspend=n
|
||||
AppDataDownloadUrl="!Game data|data.zip"
|
||||
InhibitSuspend=y
|
||||
AppDataDownloadUrl="!Game data|data3.zip"
|
||||
VideoDepthBpp=16
|
||||
NeedDepthBuffer=n
|
||||
NeedStencilBuffer=n
|
||||
@@ -30,12 +30,12 @@ RedefinedKeys="RETURN"
|
||||
AppTouchscreenKeyboardKeysAmount=0
|
||||
AppTouchscreenKeyboardKeysAmountAutoFire=0
|
||||
RedefinedKeysScreenKb="RETURN SPACE"
|
||||
StartupMenuButtonTimeout=0
|
||||
HiddenMenuOptions='DisplaySizeConfig'
|
||||
FirstStartMenuOptions=''
|
||||
StartupMenuButtonTimeout=1000
|
||||
HiddenMenuOptions='DisplaySizeConfig MouseConfigMainMenu'
|
||||
FirstStartMenuOptions='new Settings.VideoSettingsConfig()'
|
||||
MultiABI=n
|
||||
AppVersionCode=1301
|
||||
AppVersionName="1.3.01"
|
||||
AppVersionCode=1401
|
||||
AppVersionName="1.4.01"
|
||||
ResetSdlConfigForThisVersion=n
|
||||
DeleteFilesOnUpgrade="%"
|
||||
CompiledLibraries="sdl_image sdl_mixer"
|
||||
|
||||
Binary file not shown.
@@ -151,11 +151,13 @@ int main( int argc, char *argv[] )
|
||||
loadHiScore( &Game );
|
||||
enterState = cStateGame;
|
||||
break;
|
||||
#ifndef __ANDROID__
|
||||
case cOptionNewMultiplayer:
|
||||
initGame( &Game );
|
||||
Game.mode = cModeMultiplayer;
|
||||
enterState = cStateGame;
|
||||
break;
|
||||
#endif
|
||||
case cOptionHall:
|
||||
enterState = cStateHallView;
|
||||
break;
|
||||
@@ -455,6 +457,7 @@ BNX_BOOL takePair( BNX_GAME *game, BNX_INT16 x, BNX_INT16 y, BNX_INT16 pIndex )
|
||||
{
|
||||
BNX_UINT8 pair = game->grid[ x ][ y ];
|
||||
BNX_BOOL cantake = BNX_FALSE;
|
||||
BNX_UINT8 player = game->player[ pIndex ].e;
|
||||
|
||||
if ( pair == 0 )
|
||||
{
|
||||
@@ -462,12 +465,12 @@ BNX_BOOL takePair( BNX_GAME *game, BNX_INT16 x, BNX_INT16 y, BNX_INT16 pIndex )
|
||||
return BNX_TRUE;
|
||||
}
|
||||
|
||||
if ( pairLeft( pair ) == game->player[ pIndex ].e )
|
||||
if ( pairLeft( pair ) == player )
|
||||
{
|
||||
game->player[ pIndex ].e = pairRight( pair );
|
||||
cantake = BNX_TRUE;
|
||||
}
|
||||
else if ( pairRight( pair ) == game->player[ pIndex ].e )
|
||||
else if ( pairRight( pair ) == player )
|
||||
{
|
||||
game->player[ pIndex ].e = pairLeft( pair );
|
||||
cantake = BNX_TRUE;
|
||||
@@ -479,6 +482,7 @@ BNX_BOOL takePair( BNX_GAME *game, BNX_INT16 x, BNX_INT16 y, BNX_INT16 pIndex )
|
||||
|
||||
if ( cantake == BNX_TRUE )
|
||||
{
|
||||
gfxNewFallingBlock( x, y, player );
|
||||
game->grid[ x ][ y ] = cPlayerFlag;
|
||||
game->score[ pIndex ] += cScoreStep;
|
||||
}
|
||||
@@ -489,7 +493,7 @@ BNX_BOOL takePair( BNX_GAME *game, BNX_INT16 x, BNX_INT16 y, BNX_INT16 pIndex )
|
||||
BNX_BOOL moveUp( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
{
|
||||
BNX_PLAYER *p = &game->player[ pIndex ];
|
||||
BNX_INT8 newY = p->y + 1;
|
||||
BNX_INT16 newY = p->y + 1;
|
||||
|
||||
if ( newY < cGridY )
|
||||
{
|
||||
@@ -507,7 +511,7 @@ BNX_BOOL moveUp( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
BNX_BOOL moveDown( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
{
|
||||
BNX_PLAYER *p = &game->player[ pIndex ];
|
||||
BNX_INT8 newY = p->y - 1;
|
||||
BNX_INT16 newY = p->y - 1;
|
||||
|
||||
if ( newY >= 0 )
|
||||
{
|
||||
@@ -525,7 +529,7 @@ BNX_BOOL moveDown( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
BNX_BOOL moveLeft( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
{
|
||||
BNX_PLAYER *p = &game->player[ pIndex ];
|
||||
BNX_INT8 newX = p->x - 1;
|
||||
BNX_INT16 newX = p->x - 1;
|
||||
|
||||
if ( newX >= 0 )
|
||||
{
|
||||
@@ -543,7 +547,7 @@ BNX_BOOL moveLeft( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
BNX_BOOL moveRight( BNX_GAME *game, BNX_INT16 pIndex )
|
||||
{
|
||||
BNX_PLAYER *p = &game->player[ pIndex ];
|
||||
BNX_INT8 newX = p->x + 1;
|
||||
BNX_INT16 newX = p->x + 1;
|
||||
|
||||
if ( newX < cGridX )
|
||||
{
|
||||
@@ -633,6 +637,7 @@ BNX_INT16 gameSession( BNX_GAME *game )
|
||||
BNX_BOOL prevIngame = BNX_FALSE;
|
||||
|
||||
inpInit();
|
||||
gfxInitFallingBlocks();
|
||||
while ( bgameSes )
|
||||
{
|
||||
startTime = sysGetTime();
|
||||
|
||||
@@ -136,7 +136,9 @@ enum BNX_Options
|
||||
cOptionContinue = 0,
|
||||
cOptionNewRealtime,
|
||||
cOptionNewTurn,
|
||||
#ifndef __ANDROID__
|
||||
cOptionNewMultiplayer,
|
||||
#endif
|
||||
cOptionHall,
|
||||
cOptionHelp,
|
||||
cOptionQuit,
|
||||
|
||||
@@ -30,7 +30,6 @@ INCLUDES
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <android/log.h>
|
||||
|
||||
#include "inc.h"
|
||||
#include "txt.h"
|
||||
@@ -55,6 +54,9 @@ void gfxNewParticle( BNX_INT16 x, BNX_INT16 y );
|
||||
void gfxUpdateParticles();
|
||||
void gfxRenderParticles();
|
||||
|
||||
void gfxUpdateFallingBlocks();
|
||||
void gfxRenderFallingBlocks();
|
||||
|
||||
void gfxRoadmap( BNX_INT32 prev, BNX_INT32 score );
|
||||
|
||||
|
||||
@@ -93,6 +95,7 @@ BNX_BOOL gfxInit()
|
||||
}
|
||||
|
||||
gfxInitParticles();
|
||||
gfxInitFallingBlocks();
|
||||
|
||||
return BNX_TRUE;
|
||||
}
|
||||
@@ -311,6 +314,9 @@ void gfxRenderGame( BNX_GAME *game )
|
||||
gfxRenderParticles();
|
||||
gfxUpdateParticles();
|
||||
|
||||
gfxRenderFallingBlocks();
|
||||
gfxUpdateFallingBlocks();
|
||||
|
||||
/* JUMPY TEXT */
|
||||
gfxUpdateJumpyText();
|
||||
gfxRenderJumpyText();
|
||||
@@ -747,7 +753,9 @@ BNX_BOOL gfxLoadImage( char *filename, SDL_Surface **img )
|
||||
temp = IMG_Load( filename );
|
||||
if ( temp != 0 )
|
||||
{
|
||||
*img = SDL_DisplayFormat( temp );
|
||||
*img = ( temp->format->Amask == 0 ) ?
|
||||
SDL_DisplayFormat( temp ) :
|
||||
SDL_DisplayFormatAlpha( temp );
|
||||
SDL_FreeSurface( temp );
|
||||
return BNX_TRUE;
|
||||
}
|
||||
@@ -1088,3 +1096,68 @@ void gfxRenderParticles()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void gfxInitFallingBlocks()
|
||||
{
|
||||
BNX_INT16 j;
|
||||
|
||||
for ( j = 0; j < cGfxMaxParticles; ++j )
|
||||
{
|
||||
_Gfx.falling_blocks[ j ].id = -1;
|
||||
}
|
||||
}
|
||||
|
||||
void gfxNewFallingBlock( BNX_INT16 x, BNX_INT16 y, BNX_INT16 id )
|
||||
{
|
||||
BNX_INT16 j;
|
||||
|
||||
for ( j = 0; j < cGfxMaxParticles; ++j )
|
||||
{
|
||||
if ( _Gfx.falling_blocks[ j ].id < 0 )
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
j %= cGfxMaxParticles;
|
||||
_Gfx.falling_blocks[ j ].id = id;
|
||||
_Gfx.falling_blocks[ j ].x = cGfxZeroX + x * cGfxPairPlusX;
|
||||
_Gfx.falling_blocks[ j ].y = cGfxZeroY + y * cGfxPairPlusY + cGfxParticleFall;
|
||||
_Gfx.falling_blocks[ j ].dx = cGfxParticleSpeed - ( sysRand( cGfxParticleSpeed<<1 ) + cGfxParticleMinSp );
|
||||
_Gfx.falling_blocks[ j ].dy = cGfxParticleFall;
|
||||
}
|
||||
|
||||
void gfxUpdateFallingBlocks()
|
||||
{
|
||||
BNX_INT16 j;
|
||||
|
||||
for ( j = 0; j < cGfxMaxParticles; ++j )
|
||||
{
|
||||
if ( _Gfx.falling_blocks[ j ].id >= 0 )
|
||||
{
|
||||
_Gfx.falling_blocks[ j ].x += _Gfx.falling_blocks[ j ].dx;
|
||||
_Gfx.falling_blocks[ j ].y += _Gfx.falling_blocks[ j ].dy;
|
||||
_Gfx.falling_blocks[ j ].dy += cGfxParticleFall;
|
||||
if( _Gfx.falling_blocks[ j ].y >= cGfxScreenY )
|
||||
_Gfx.falling_blocks[ j ].id = -1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void gfxRenderFallingBlocks()
|
||||
{
|
||||
BNX_INT16 j;
|
||||
SDL_Rect pos;
|
||||
|
||||
for ( j = 0; j < cGfxMaxParticles; ++j )
|
||||
{
|
||||
if ( _Gfx.falling_blocks[ j ].id >= 0 )
|
||||
{
|
||||
pos.x = _Gfx.falling_blocks[ j ].x;
|
||||
pos.y = _Gfx.falling_blocks[ j ].y;
|
||||
|
||||
SDL_BlitSurface( _Gfx.elements[ _Gfx.falling_blocks[ j ].id ], NULL, _Gfx.screen, &pos );
|
||||
pos.x += cGfxNextPlusX;
|
||||
SDL_BlitSurface( _Gfx.elements[ _Gfx.falling_blocks[ j ].id ], NULL, _Gfx.screen, &pos );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -178,7 +178,9 @@ static BNX_BOX _BNX_MENU_BOXES[ cMaxOptions ] = {
|
||||
{ 241, 395, 420, 420 },
|
||||
{ 232, 430, 426, 457 },
|
||||
{ 296, 468, 364, 492 },
|
||||
#ifndef __ANDROID__
|
||||
{ 295, 503, 362, 528 }
|
||||
#endif
|
||||
};
|
||||
|
||||
static char virtualKBD[ cGfxKeyGridY ][ cGfxKeyGridX ] = {
|
||||
@@ -204,6 +206,15 @@ typedef struct BNX_PARTICLE
|
||||
|
||||
} BNX_PARTICLE;
|
||||
|
||||
typedef struct BNX_FALLINGBLOCK
|
||||
{
|
||||
BNX_INT16 x;
|
||||
BNX_INT16 y;
|
||||
BNX_INT16 dx;
|
||||
BNX_INT16 dy;
|
||||
BNX_INT16 id;
|
||||
} BNX_FALLINGBLOCK;
|
||||
|
||||
typedef struct BNX_JUMPYTEXT
|
||||
{
|
||||
BNX_INT16 x;
|
||||
@@ -238,6 +249,7 @@ typedef struct BNX_GFX
|
||||
BNX_JUMPYTEXT jtext;
|
||||
|
||||
BNX_PARTICLE particle[ cGfxMaxParticles ];
|
||||
BNX_FALLINGBLOCK falling_blocks[ cGfxMaxParticles ];
|
||||
|
||||
} BNX_GFX;
|
||||
|
||||
@@ -273,6 +285,9 @@ BNX_INT16 gfxGetMenuOption( BNX_INP *inp );
|
||||
|
||||
void gfxGetHelpPen( BNX_INP *inp );
|
||||
|
||||
void gfxInitFallingBlocks();
|
||||
void gfxNewFallingBlock( BNX_INT16 x, BNX_INT16 y, BNX_INT16 id );
|
||||
|
||||
/******************************************************************************
|
||||
HELPER FUNCTIONS
|
||||
******************************************************************************/
|
||||
|
||||
@@ -28,7 +28,6 @@ For complete product license refer to LICENSE.TXT file
|
||||
INCLUDES
|
||||
******************************************************************************/
|
||||
#include <string.h>
|
||||
#include <SDL_screenkeyboard.h>
|
||||
|
||||
#include "inc.h"
|
||||
|
||||
@@ -222,10 +221,6 @@ BNX_BOOL hofEnter( BNX_GAME *game )
|
||||
|
||||
strcpy( recEntry->name, " " );
|
||||
recEntry->score = game->score[ cPlayer1 ];
|
||||
#ifdef __ANDROID__
|
||||
//strcpy( recEntry->name, "Player" );
|
||||
//SDL_ANDROID_GetScreenKeyboardTextInput(recEntry->name, 30);
|
||||
#endif
|
||||
inpInit();
|
||||
do
|
||||
{
|
||||
|
||||
@@ -38,7 +38,9 @@ char *TXT_MenuMain[ cMaxOptions ] = {
|
||||
"CONTINUE LAST GAME",
|
||||
"NEW ARCADE GAME",
|
||||
"NEW TACTIC GAME",
|
||||
#ifndef __ANDROID__
|
||||
"MULTIPLAYER",
|
||||
#endif
|
||||
"HALL OF FAME",
|
||||
"HELP",
|
||||
"EXIT"
|
||||
|
||||
@@ -39,7 +39,7 @@ typedef unsigned int BNX_UINT32;
|
||||
SIGNED TYPES
|
||||
******************************************************************************/
|
||||
|
||||
typedef char BNX_INT8;
|
||||
typedef signed char BNX_INT8; /* Default char type is unsigned on Android, that breaks some logic inside Biniax2 */
|
||||
typedef short int BNX_INT16;
|
||||
typedef int BNX_INT32;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user