mirror of
https://github.com/smartcmd/MinecraftConsoles.git
synced 2026-08-20 09:57:09 +00:00
now possible to accept and decline tutorial hints
that part when it asks if you want to do the tutorial (should work for when the games asks if you already know something like when opening inventories for the first time)
This commit is contained in:
parent
071d4f6599
commit
6b3a051fc0
|
|
@ -7,6 +7,7 @@
|
|||
#include "TutorialConstraints.h"
|
||||
#include "ChoiceTask.h"
|
||||
#include "..\..\..\Minecraft.World\Material.h"
|
||||
#include "..\..\Windows64\KeyboardMouseInput.h"
|
||||
|
||||
ChoiceTask::ChoiceTask(Tutorial *tutorial, int descriptionId, int promptId /*= -1*/, bool requiresUserInput /*= false*/,
|
||||
int iConfirmMapping /*= 0*/, int iCancelMapping /*= 0*/,
|
||||
|
|
@ -51,11 +52,11 @@ bool ChoiceTask::isCompleted()
|
|||
// If the player is under water then allow all keypresses so they can jump out
|
||||
if( pMinecraft->localplayers[tutorial->getPad()]->isUnderLiquid(Material::water) ) return false;
|
||||
|
||||
if(!m_bConfirmMappingComplete && InputManager.GetValue(pMinecraft->player->GetXboxPad(), m_iConfirmMapping) > 0 )
|
||||
if(!m_bConfirmMappingComplete && InputManager.GetValue(pMinecraft->player->GetXboxPad(), m_iConfirmMapping) > 0 || KMInput.IsKeyDown(VK_RETURN))
|
||||
{
|
||||
m_bConfirmMappingComplete = true;
|
||||
}
|
||||
if(!m_bCancelMappingComplete && InputManager.GetValue(pMinecraft->player->GetXboxPad(), m_iCancelMapping) > 0 )
|
||||
if(!m_bCancelMappingComplete && InputManager.GetValue(pMinecraft->player->GetXboxPad(), m_iCancelMapping) > 0 || KMInput.IsKeyDown('B'))
|
||||
{
|
||||
m_bCancelMappingComplete = true;
|
||||
}
|
||||
|
|
@ -99,11 +100,11 @@ void ChoiceTask::handleUIInput(int iAction)
|
|||
{
|
||||
if(bHasBeenActivated && m_bShownForMinimumTime)
|
||||
{
|
||||
if( iAction == m_iConfirmMapping )
|
||||
if( iAction == m_iConfirmMapping || KMInput.IsKeyDown(41))
|
||||
{
|
||||
m_bConfirmMappingComplete = true;
|
||||
}
|
||||
else if(iAction == m_iCancelMapping )
|
||||
else if(iAction == m_iCancelMapping || KMInput.IsKeyDown(42))
|
||||
{
|
||||
m_bCancelMappingComplete = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ This project contains the source code of Minecraft Legacy Console Edition v1.3.0
|
|||
- **Attack / Destroy**: `Left Click`
|
||||
- **Use / Place**: `Right Click`
|
||||
- **Select Item**: `Mouse Wheel` or keys `1` to `9`
|
||||
- **Accept or Decline Tutorial hints**: `Enter` to accept and `B` to decline
|
||||
|
||||
## Build & Run
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue