/* =============== CG_HumanCkitText =============== */ static void CG_HumanCkitText( char *text, playerState_t *ps ) { buildable_t buildable = ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT; if( buildable > BA_NONE ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to place the %s\n", CG_KeyNameForCommand( "+attack" ), BG_FindHumanNameForBuildable( buildable ) ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to cancel placing the %s\n", CG_KeyNameForCommand( "+button5" ), BG_FindHumanNameForBuildable( buildable ) ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to build a structure\n", CG_KeyNameForCommand( "+attack" ) ) ); if( CG_BuildableInRange( ps ) ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to destroy this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } } }
/* =============== CG_HumanCkitText =============== */ static void CG_HumanCkitText( char *text, playerState_t *ps ) { buildable_t buildable = ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT; entityState_t *es; if( buildable > BA_NONE ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to place the %s\n", CG_KeyNameForCommand( "+attack" ), BG_Buildable( buildable )->humanName ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to cancel placing the %s\n", CG_KeyNameForCommand( "+button5" ), BG_Buildable( buildable )->humanName ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to build a structure\n", CG_KeyNameForCommand( "+attack" ) ) ); } if( ( es = CG_BuildableInRange( ps, NULL ) ) ) { if( cgs.markDeconstruct ) { if( es->eFlags & EF_B_MARKED ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to unmark this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to mark this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to destroy this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } } }
/* =============== CG_AlienBuilderText =============== */ static void CG_AlienBuilderText( char *text, playerState_t *ps ) { buildable_t buildable = ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT; if( buildable > BA_NONE ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to place the %s\n", CG_KeyNameForCommand( "+attack" ), BG_FindHumanNameForBuildable( buildable ) ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to cancel placing the %s\n", CG_KeyNameForCommand( "+button5" ), BG_FindHumanNameForBuildable( buildable ) ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to build a structure\n", CG_KeyNameForCommand( "+attack" ) ) ); if( CG_BuildableInRange( ps ) ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to destroy this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } } /*if( ps->stats[ STAT_PCLASS ] == PCL_ALIEN_BUILDER0_UPG ) { if( ( ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT ) == BA_NONE ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to swipe\n", CG_KeyNameForCommand( "+button5" ) ) ); } Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to launch a projectile\n", CG_KeyNameForCommand( "+button2" ) ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to walk on walls\n", CG_KeyNameForCommand( "+movedown" ) ) ); }*/ }
/* =============== CG_BuilderText =============== */ static void CG_BuilderText( char *text, playerState_t *ps ) { buildable_t buildable = ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT; entityState_t *es; if ( buildable > BA_NONE ) { const char *item = _( BG_Buildable( buildable )->humanName ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( _( "Press %s to place the %s\n"), CG_KeyNameForCommand( "+attack" ), item ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( _( "Press %s to cancel placing the %s\n" ), CG_KeyNameForCommand( "+attack2" ), item ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( _( "Press %s to build a structure\n" ), CG_KeyNameForCommand( "+attack" ) ) ); } if ( ( es = CG_BuildableInRange( ps, NULL ) ) ) { const char *key = CG_KeyNameForCommand( "if alt \"/deconstruct marked\" /deconstruct" ); if ( cgs.markDeconstruct ) { if ( es->eFlags & EF_B_MARKED ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( _( "Press %s to unmark this structure for replacement\n" ), key ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( _( "Press %s to mark this structure for replacement\n" ), key ) ); } } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( _( "Press %s to destroy this structure\n" ), key ) ); } } }
/* =============== CG_AlienBuilderText =============== */ static void CG_AlienBuilderText( char *text, playerState_t *ps ) { buildable_t buildable = ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT; entityState_t *es; if( buildable > BA_NONE ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to place the %s\n", CG_KeyNameForCommand( "+attack" ), BG_Buildable( buildable )->humanName ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to cancel placing the %s\n", CG_KeyNameForCommand( "+button5" ), BG_Buildable( buildable )->humanName ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to build a structure\n", CG_KeyNameForCommand( "+attack" ) ) ); } if( ( es = CG_BuildableInRange( ps, NULL ) ) ) { if( cgs.markDeconstruct ) { if( es->eFlags & EF_B_MARKED ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to unmark this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to mark this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } } else { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to destroy this structure\n", CG_KeyNameForCommand( "deconstruct" ) ) ); } } if( ( ps->stats[ STAT_BUILDABLE ] & ~SB_VALID_TOGGLEBIT ) == BA_NONE ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to swipe\n", CG_KeyNameForCommand( "+button5" ) ) ); } if( ps->stats[ STAT_CLASS ] == PCL_ALIEN_BUILDER0_UPG ) { Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to launch a projectile\n", CG_KeyNameForCommand( "+button2" ) ) ); Q_strcat( text, MAX_TUTORIAL_TEXT, va( "Press %s to walk on walls\n", CG_KeyNameForCommand( "+movedown" ) ) ); } }