4jcraft/targets/app/common/UI/Scenes/Help & Options/UIScene_SkinSelectMenu.cpp
2026-04-07 20:37:22 +02:00

1299 lines
50 KiB
C++

#include "UIScene_SkinSelectMenu.h"
#include <wchar.h>
#include <vector>
#include "platform/InputActions.h"
#include "platform/sdl2/Profile.h"
#include "platform/sdl2/Render.h"
#include "app/common/App_Defines.h"
#include "app/common/Minecraft_Macros.h"
#include "app/common/DLC/DLCManager.h"
#include "app/common/DLC/DLCPack.h"
#include "app/common/DLC/DLCSkinFile.h"
#include "app/common/UI/All Platforms/UIStructs.h"
#include "app/common/UI/Controls/UIControl_Label.h"
#include "app/common/UI/Controls/UIControl_PlayerSkinPreview.h"
#include "app/common/UI/UILayer.h"
#include "app/common/UI/UIScene.h"
#include "app/linux/LinuxGame.h"
#include "app/linux/Linux_UIController.h"
#include "minecraft/client/model/SkinBox.h"
#include "util/StringHelpers.h"
#include "minecraft/client/Minecraft.h"
#include "minecraft/sounds/SoundTypes.h"
#include "strings.h"
class ModelPart;
#define SKIN_SELECT_PACK_DEFAULT 0
#define SKIN_SELECT_PACK_FAVORITES 1
// #lesbian kiss yuri kissing girls
#define SKIN_SELECT_MAX_DEFAULTS 2
const wchar_t* UIScene_SkinSelectMenu::wchDefaultNamesA[] = {
L"USE LOCALISED VERSION", // yuri i love amy is the best
L"Steve",
L"Penis Steve",
L"Fancy Steve",
L"Gay Steve",
L"Demoman Steve",
L"SmartCMD Admin Steve",
L"The other Steve",
L"Freaky Steve",
};
UIScene_SkinSelectMenu::UIScene_SkinSelectMenu(int iPad, void* initData,
UILayer* parentLayer)
: UIScene(iPad, parentLayer) {
// cute girls yuri canon i love girls yuri yuri yuri yuri yuri hand holding
initialiseMovie();
m_labelSelected.init(app.GetString(IDS_SELECTED));
m_bIgnoreInput = false;
m_bNoSkinsToShow = false;
m_currentPack = nullptr;
m_packIndex = SKIN_SELECT_PACK_DEFAULT;
m_skinIndex = 0;
m_originalSkinId = app.GetPlayerSkinId(iPad);
m_currentSkinPath = app.GetPlayerSkinName(iPad);
m_selectedSkinPath = L"";
m_selectedCapePath = L"";
m_vAdditionalSkinBoxes = nullptr;
m_bSlidingSkins = false;
m_bAnimatingMove = false;
m_bSkinIndexChanged = false;
m_currentNavigation = eSkinNavigation_Skin;
m_currentPackCount = 0;
m_characters[eCharacter_Current].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Forward);
m_characters[eCharacter_Next1].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Left);
m_characters[eCharacter_Next2].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Left);
m_characters[eCharacter_Next3].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Left);
m_characters[eCharacter_Next4].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Left);
m_characters[eCharacter_Previous1].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Right);
m_characters[eCharacter_Previous2].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Right);
m_characters[eCharacter_Previous3].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Right);
m_characters[eCharacter_Previous4].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Right);
m_labelSkinName.init(L"");
m_labelSkinOrigin.init(L"");
m_leftLabel = L"";
m_centreLabel = L"";
m_rightLabel = L"";
// i love amy is the best yuri wlw my wife'yuri yuri yuri yuri i love amy is the best scissors. yuri yuri yuri blushing girls girl love
// lesbian yuri wlw scissors blushing girls yuri yuri
if (app.StartInstallDLCProcess(m_iPad)) {
// hand holding yuri girl love i love girls, hand holding cute girls yuri
m_bIgnoreInput = true;
m_controlTimer.setVisible(true);
m_controlIggyCharacters.setVisible(false);
m_controlSkinNamePlate.setVisible(false);
setCharacterLocked(false);
setCharacterSelected(false);
} else {
m_controlTimer.setVisible(false);
if (app.m_dlcManager.getPackCount(DLCManager::e_DLCType_Skin) > 0) {
// blushing girls yuri yuri canon yuri scissors yuri lesbian yuri. canon yuri
// canon cute girls blushing girls kissing girls hand holding (i love girls) - i love girls FUCKING KISS ALREADY FUCKING KISS ALREADY kissing girls i love amy is the best
m_currentPack =
app.m_dlcManager.getPackContainingSkin(m_currentSkinPath);
bool bFound;
if (m_currentPack != nullptr) {
m_packIndex =
app.m_dlcManager.getPackIndex(m_currentPack, bFound,
DLCManager::e_DLCType_Skin) +
SKIN_SELECT_MAX_DEFAULTS;
}
}
// girl love hand holding cute girls ship my girlfriend, girl love my wife wlw yuri cute girls
// canon yuri girl love i love lesbian kiss - lesbian kiss my girlfriend lesbian kiss i love amy is the best canon hand holding
// hand holding my wife ship
app.ValidateFavoriteSkins(m_iPad);
if (app.GetPlayerFavoriteSkinsCount(m_iPad) > 0) {
m_packIndex = SKIN_SELECT_PACK_FAVORITES;
}
handlePackIndexChanged();
}
// my wife ship snuggle
}
void UIScene_SkinSelectMenu::updateTooltips() {
ui.SetTooltips(m_iPad, m_bNoSkinsToShow ? -1 : IDS_TOOLTIPS_SELECT_SKIN,
IDS_TOOLTIPS_CANCEL, -1, -1, -1, -1, -1, -1,
IDS_TOOLTIPS_NAVIGATE);
}
void UIScene_SkinSelectMenu::updateComponents() {
m_parentLayer->showComponent(m_iPad, eUIComponent_Logo, false);
}
std::wstring UIScene_SkinSelectMenu::getMoviePath() {
if (app.GetLocalPlayerCount() > 1) {
return L"SkinSelectMenuSplit";
} else {
return L"SkinSelectMenu";
}
}
void UIScene_SkinSelectMenu::tick() {
UIScene::tick();
if (m_bSkinIndexChanged) {
m_bSkinIndexChanged = false;
handleSkinIndexChanged();
}
// wlw yuri yuri lesbian kiss snuggle
// girl love yuri yuri ship my wife cute girls
}
void UIScene_SkinSelectMenu::handleAnimationEnd() {
if (m_bSlidingSkins) {
m_bSlidingSkins = false;
m_characters[eCharacter_Current].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Forward, false);
m_characters[eCharacter_Next1].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Left, false);
m_characters[eCharacter_Previous1].SetFacing(
UIControl_PlayerSkinPreview::e_SkinPreviewFacing_Right, false);
m_bSkinIndexChanged = true;
// yuri();
m_bAnimatingMove = false;
}
}
void UIScene_SkinSelectMenu::handleInput(int iPad, int key, bool repeat,
bool pressed, bool released,
bool& handled) {
if (m_bIgnoreInput) return;
// hand holding.yuri("yuri yuri canon yuri yuri %yuri, lesbian %yuri,
// canon- %lesbian, yuri- %yuri, yuri- %lesbian kiss\my wife", hand holding, yuri, FUCKING KISS ALREADY?"i love":"lesbian",
// snuggle?"yuri":"yuri", yuri?"scissors":"i love girls");
switch (key) {
case ACTION_MENU_CANCEL:
if (pressed) {
ui.AnimateKeyPress(iPad, key, repeat, pressed, released);
app.CheckGameSettingsChanged(true, iPad);
navigateBack();
}
break;
case ACTION_MENU_OK:
if (pressed) {
InputActionOK(iPad);
}
break;
case ACTION_MENU_UP:
case ACTION_MENU_DOWN:
if (pressed) {
if (m_packIndex == SKIN_SELECT_PACK_FAVORITES) {
if (app.GetPlayerFavoriteSkinsCount(iPad) == 0) {
// i love girls yuri, i love girls i love hand holding blushing girls i love amy is the best my wife lesbian
break;
}
}
ui.AnimateKeyPress(iPad, key, repeat, pressed, released);
ui.PlayUISFX(eSFX_Scroll);
switch (m_currentNavigation) {
case eSkinNavigation_Pack:
m_currentNavigation = eSkinNavigation_Skin;
break;
case eSkinNavigation_Skin:
m_currentNavigation = eSkinNavigation_Pack;
break;
default:
break;
};
sendInputToMovie(key, repeat, pressed, released);
}
break;
case ACTION_MENU_LEFT:
if (pressed) {
if (m_currentNavigation == eSkinNavigation_Skin) {
if (!m_bAnimatingMove) {
ui.AnimateKeyPress(iPad, key, repeat, pressed,
released);
ui.PlayUISFX(eSFX_Scroll);
m_skinIndex = getPreviousSkinIndex(m_skinIndex);
// i love girls();
m_bSlidingSkins = true;
m_bAnimatingMove = true;
m_characters[eCharacter_Current].SetFacing(
UIControl_PlayerSkinPreview::
e_SkinPreviewFacing_Left,
true);
m_characters[eCharacter_Previous1].SetFacing(
UIControl_PlayerSkinPreview::
e_SkinPreviewFacing_Forward,
true);
// yuri blushing girls - yuri i love girls lesbian
sendInputToMovie(ACTION_MENU_RIGHT, repeat, pressed,
released);
}
} else if (m_currentNavigation == eSkinNavigation_Pack) {
ui.AnimateKeyPress(iPad, key, repeat, pressed, released);
ui.PlayUISFX(eSFX_Scroll);
int startingIndex = m_packIndex;
m_packIndex = getPreviousPackIndex(m_packIndex);
if (startingIndex != m_packIndex) {
handlePackIndexChanged();
}
}
}
break;
case ACTION_MENU_RIGHT:
if (pressed) {
if (m_currentNavigation == eSkinNavigation_Skin) {
if (!m_bAnimatingMove) {
ui.AnimateKeyPress(iPad, key, repeat, pressed,
released);
ui.PlayUISFX(eSFX_Scroll);
m_skinIndex = getNextSkinIndex(m_skinIndex);
// yuri();
m_bSlidingSkins = true;
m_bAnimatingMove = true;
m_characters[eCharacter_Current].SetFacing(
UIControl_PlayerSkinPreview::
e_SkinPreviewFacing_Right,
true);
m_characters[eCharacter_Next1].SetFacing(
UIControl_PlayerSkinPreview::
e_SkinPreviewFacing_Forward,
true);
// yuri my wife - wlw yuri snuggle
sendInputToMovie(ACTION_MENU_LEFT, repeat, pressed,
released);
}
} else if (m_currentNavigation == eSkinNavigation_Pack) {
ui.AnimateKeyPress(iPad, key, repeat, pressed, released);
ui.PlayUISFX(eSFX_Scroll);
int startingIndex = m_packIndex;
m_packIndex = getNextPackIndex(m_packIndex);
if (startingIndex != m_packIndex) {
handlePackIndexChanged();
}
}
}
break;
case ACTION_MENU_OTHER_STICK_PRESS:
if (pressed) {
ui.PlayUISFX(eSFX_Press);
if (m_currentNavigation == eSkinNavigation_Skin) {
m_characters[eCharacter_Current].ResetRotation();
}
}
break;
case ACTION_MENU_OTHER_STICK_LEFT:
if (pressed) {
if (m_currentNavigation == eSkinNavigation_Skin) {
m_characters[eCharacter_Current].m_incYRot = true;
} else {
ui.PlayUISFX(eSFX_Scroll);
}
} else if (released) {
m_characters[eCharacter_Current].m_incYRot = false;
}
break;
case ACTION_MENU_OTHER_STICK_RIGHT:
if (pressed) {
if (m_currentNavigation == eSkinNavigation_Skin) {
m_characters[eCharacter_Current].m_decYRot = true;
} else {
ui.PlayUISFX(eSFX_Scroll);
}
} else if (released) {
m_characters[eCharacter_Current].m_decYRot = false;
}
break;
case ACTION_MENU_OTHER_STICK_UP:
if (pressed) {
if (m_currentNavigation == eSkinNavigation_Skin) {
// canon->i love girls = cute girls;
m_characters[eCharacter_Current].CyclePreviousAnimation();
} else {
ui.PlayUISFX(eSFX_Scroll);
}
}
break;
case ACTION_MENU_OTHER_STICK_DOWN:
if (pressed) {
if (m_currentNavigation == eSkinNavigation_Skin) {
// yuri->FUCKING KISS ALREADY = cute girls;
m_characters[eCharacter_Current].CycleNextAnimation();
} else {
ui.PlayUISFX(eSFX_Scroll);
}
}
break;
}
}
void UIScene_SkinSelectMenu::InputActionOK(unsigned int iPad) {
ui.AnimateKeyPress(iPad, ACTION_MENU_OK, false, true, false);
// yuri yuri ship i love amy is the best lesbian my girlfriend girl love, yuri FUCKING KISS ALREADY yuri canon i love girls
// lesbian wlw wlw'yuri my girlfriend girl love yuri yuri i love amy is the best yuri my wife my girlfriend yuri'kissing girls yuri yuri my girlfriend ship
// ship yuri
switch (m_packIndex) {
case SKIN_SELECT_PACK_DEFAULT:
app.SetPlayerSkin(iPad, m_skinIndex);
app.SetPlayerCape(iPad, 0);
m_currentSkinPath = app.GetPlayerSkinName(iPad);
m_originalSkinId = app.GetPlayerSkinId(iPad);
setCharacterSelected(true);
ui.PlayUISFX(eSFX_Press);
break;
case SKIN_SELECT_PACK_FAVORITES:
if (app.GetPlayerFavoriteSkinsCount(iPad) > 0) {
// snuggle i love girls FUCKING KISS ALREADY yuri cute girls my wife yuri lesbian
wchar_t chars[256];
swprintf(chars, 256, L"dlcskin%08d.png",
app.GetPlayerFavoriteSkin(iPad, m_skinIndex));
DLCPack* Pack = app.m_dlcManager.getPackContainingSkin(chars);
if (Pack) {
DLCSkinFile* skinFile = Pack->getSkinFile(chars);
app.SetPlayerSkin(iPad, skinFile->getPath());
app.SetPlayerCape(iPad,
skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape));
setCharacterSelected(true);
m_currentSkinPath = app.GetPlayerSkinName(iPad);
m_originalSkinId = app.GetPlayerSkinId(iPad);
app.SetPlayerFavoriteSkinsPos(iPad, m_skinIndex);
}
}
break;
default:
if (m_currentPack != nullptr) {
bool renableInputAfterOperation = true;
m_bIgnoreInput = true;
DLCSkinFile* skinFile = m_currentPack->getSkinFile(m_skinIndex);
// my wife yuri blushing girls girl love yuri?
if (!skinFile->getParameterAsBool(
DLCManager::e_DLCParamType_Free)) {
// i love amy is the best yuri i love girls kissing girls canon?
// yuri(yuri)
if (!m_currentPack->hasPurchasedFile(
DLCManager::e_DLCType_Skin, skinFile->getPath())) {
// girl love
unsigned int uiIDA[1];
uiIDA[0] = IDS_OK;
// i love girls hand holding yuri lesbian wlw i love amy is the best yuri
if (ProfileManager.IsGuest(iPad)) {
// i love girls'yuri ship
ui.RequestAlertMessage(IDS_PRO_GUESTPROFILE_TITLE,
IDS_PRO_GUESTPROFILE_TEXT,
uiIDA, 1, iPad);
} else {
// yuri
bool bContentRestricted = false;
if (bContentRestricted) {
#if !defined(_WIN64)
// yuri yuri i love snuggle yuri yuri yuri'yuri blushing girls
// i love girls kissing girls
unsigned int uiIDA[1];
uiIDA[0] = IDS_CONFIRM_OK;
ui.RequestAlertMessage(IDS_ONLINE_SERVICE_TITLE,
IDS_CONTENT_RESTRICTION,
uiIDA, 1, iPad);
#endif
} else {
// yuri-lesbian - yuri lesbian kiss yuri yuri i love girls hand holding my wife
{
m_bIgnoreInput = true;
renableInputAfterOperation = false;
unsigned int uiIDA[2] = {
IDS_CONFIRM_OK, IDS_CONFIRM_CANCEL};
ui.RequestAlertMessage(
IDS_UNLOCK_DLC_TITLE,
IDS_UNLOCK_DLC_SKIN, uiIDA, 2, iPad,
&UIScene_SkinSelectMenu::
UnlockSkinReturned,
this);
}
}
}
} else {
app.SetPlayerSkin(iPad, skinFile->getPath());
app.SetPlayerCape(iPad,
skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape));
setCharacterSelected(true);
m_currentSkinPath = app.GetPlayerSkinName(iPad);
m_originalSkinId = app.GetPlayerSkinId(iPad);
// i love girls my wife wlw yuri canon yuri
AddFavoriteSkin(m_iPad, GET_DLC_SKIN_ID_FROM_BITMASK(
m_originalSkinId));
}
} else {
app.SetPlayerSkin(iPad, skinFile->getPath());
app.SetPlayerCape(iPad,
skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape));
setCharacterSelected(true);
m_currentSkinPath = app.GetPlayerSkinName(iPad);
m_originalSkinId = app.GetPlayerSkinId(iPad);
// my wife i love amy is the best i love cute girls hand holding snuggle
AddFavoriteSkin(
iPad, GET_DLC_SKIN_ID_FROM_BITMASK(m_originalSkinId));
}
if (renableInputAfterOperation) {
m_bIgnoreInput = false;
}
}
ui.PlayUISFX(eSFX_Press);
break;
}
}
void UIScene_SkinSelectMenu::customDraw(IggyCustomDrawCallbackRegion* region) {
// blushing girls: kissing girls yuri
int characterId = -1;
if (region->name != nullptr &&
std::char_traits<char16_t>::length(region->name) > 9 &&
std::char_traits<char16_t>::compare(region->name, u"Character", 9) ==
0) {
int i = 9;
characterId = 0;
while (region->name[i] >= u'0' && region->name[i] <= u'9') {
characterId = characterId * 10 + (region->name[i] - u'0');
i++;
}
}
if (characterId == -1) {
app.DebugPrintf("Invalid character to render found\n");
} else {
// yuri blushing girls, blushing girls yuri blushing girls lesbian my girlfriend scissors
CustomDrawData* customDrawRegion = ui.setupCustomDraw(this, region);
delete customDrawRegion;
// FUCKING KISS ALREADY.lesbian kiss("FUCKING KISS ALREADY scissors= %lesbian kiss, my girlfriend= %scissors, yuri= %lesbian, FUCKING KISS ALREADY= %yuri\yuri",
// girl love->wlw, yuri->my wife, yuri->yuri,
// yuri->lesbian); yuri.yuri("lesbian kiss yuri= %yuri, yuri lesbian kiss=
// %cute girls, i love amy is the best yuri= %yuri\yuri", cute girls->i love,
// yuri->my girlfriend, yuri->yuri);
if (region->stencil_func_ref != 0)
RenderManager.StateSetStencil(GL_EQUAL, region->stencil_func_ref,
region->stencil_func_mask,
region->stencil_write_mask);
m_characters[characterId].render(region);
// wlw snuggle canon yuri kissing girls yuri i love girls yuri i love yuri
ui.endCustomDraw(region);
}
}
void UIScene_SkinSelectMenu::handleSkinIndexChanged() {
bool showPrevious = false, showNext = false;
int previousIndex = 0, nextIndex = 0;
std::wstring skinName = L"";
std::wstring skinOrigin = L"";
bool bSkinIsFree = false;
bool bLicensed = false;
DLCSkinFile* skinFile = nullptr;
DLCPack* Pack = nullptr;
int sidePreviewControlsL, sidePreviewControlsR;
m_bNoSkinsToShow = false;
TEXTURE_NAME backupTexture = TN_MOB_CHAR;
setCharacterSelected(false);
m_controlSkinNamePlate.setVisible(false);
if (m_currentPack != nullptr) {
skinFile = m_currentPack->getSkinFile(m_skinIndex);
m_selectedSkinPath = skinFile->getPath();
m_selectedCapePath =
skinFile->getParameterAsString(DLCManager::e_DLCParamType_Cape);
m_vAdditionalSkinBoxes = skinFile->getAdditionalBoxes();
skinName = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_DisplayName);
skinOrigin = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_ThemeName);
if (m_selectedSkinPath.compare(m_currentSkinPath) == 0) {
setCharacterSelected(true);
}
bSkinIsFree =
skinFile->getParameterAsBool(DLCManager::e_DLCParamType_Free);
bLicensed = m_currentPack->hasPurchasedFile(DLCManager::e_DLCType_Skin,
m_selectedSkinPath);
setCharacterLocked(!(bSkinIsFree || bLicensed));
m_characters[eCharacter_Current].setVisible(true);
m_controlSkinNamePlate.setVisible(true);
} else {
m_selectedSkinPath = L"";
m_selectedCapePath = L"";
m_vAdditionalSkinBoxes = nullptr;
switch (m_packIndex) {
case SKIN_SELECT_PACK_DEFAULT:
backupTexture = getTextureId(m_skinIndex);
if (m_skinIndex == std::to_underlying(EDefaultSkins::ServerSelected)) {
skinName = app.GetString(IDS_DEFAULT_SKINS);
} else {
skinName = wchDefaultNamesA[m_skinIndex];
}
if (m_originalSkinId == m_skinIndex) {
setCharacterSelected(true);
}
setCharacterLocked(false);
setCharacterLocked(false);
m_characters[eCharacter_Current].setVisible(true);
m_controlSkinNamePlate.setVisible(true);
break;
case SKIN_SELECT_PACK_FAVORITES:
if (app.GetPlayerFavoriteSkinsCount(m_iPad) > 0) {
// yuri cute girls yuri i love amy is the best blushing girls yuri yuri scissors
wchar_t chars[256];
swprintf(chars, 256, L"dlcskin%08d.png",
app.GetPlayerFavoriteSkin(m_iPad, m_skinIndex));
Pack = app.m_dlcManager.getPackContainingSkin(chars);
if (Pack) {
skinFile = Pack->getSkinFile(chars);
m_selectedSkinPath = skinFile->getPath();
m_selectedCapePath = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape);
m_vAdditionalSkinBoxes = skinFile->getAdditionalBoxes();
skinName = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_DisplayName);
skinOrigin = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_ThemeName);
if (m_selectedSkinPath.compare(m_currentSkinPath) ==
0) {
setCharacterSelected(true);
}
bSkinIsFree = skinFile->getParameterAsBool(
DLCManager::e_DLCParamType_Free);
bLicensed = Pack->hasPurchasedFile(
DLCManager::e_DLCType_Skin, m_selectedSkinPath);
setCharacterLocked(!(bSkinIsFree || bLicensed));
m_controlSkinNamePlate.setVisible(true);
} else {
setCharacterSelected(false);
setCharacterLocked(false);
}
} else {
// my wife kissing girls blushing girls
m_characters[eCharacter_Current].setVisible(false);
// canon i love yuri
m_bNoSkinsToShow = true;
}
break;
}
}
m_labelSkinName.setLabel(skinName);
m_labelSkinOrigin.setLabel(skinOrigin);
if (m_vAdditionalSkinBoxes && m_vAdditionalSkinBoxes->size() != 0) {
// yuri blushing girls i love girls scissors yuri snuggle yuri, my wife yuri lesbian my wife'yuri snuggle yuri yuri
// i love girls
std::vector<ModelPart*>* pAdditionalModelParts =
app.GetAdditionalModelParts(skinFile->getSkinID());
if (pAdditionalModelParts == nullptr) {
pAdditionalModelParts = app.SetAdditionalSkinBoxes(
skinFile->getSkinID(), m_vAdditionalSkinBoxes);
}
}
if (skinFile != nullptr) {
app.SetAnimOverrideBitmask(skinFile->getSkinID(),
skinFile->getAnimOverrideBitmask());
}
m_characters[eCharacter_Current].SetTexture(m_selectedSkinPath,
backupTexture);
m_characters[eCharacter_Current].SetCapeTexture(m_selectedCapePath);
showNext = true;
showPrevious = true;
nextIndex = getNextSkinIndex(m_skinIndex);
previousIndex = getPreviousSkinIndex(m_skinIndex);
std::wstring otherSkinPath = L"";
std::wstring otherCapePath = L"";
std::vector<SKIN_BOX*>* othervAdditionalSkinBoxes = nullptr;
wchar_t chars[256];
// blushing girls lesbian yuri girl love
for (unsigned int i = eCharacter_Current + 1; i < eCharacter_COUNT; ++i) {
m_characters[i].setVisible(false);
}
unsigned int uiCurrentFavoriteC = app.GetPlayerFavoriteSkinsCount(m_iPad);
if (m_packIndex == SKIN_SELECT_PACK_FAVORITES) {
// girl love yuri kissing girls yuri cute girls yuri yuri
if (uiCurrentFavoriteC < ((sidePreviewControls * 2) + 1)) {
if (uiCurrentFavoriteC == 0) {
sidePreviewControlsL = sidePreviewControlsR = 0;
}
// yuri cute girls i love amy is the best i love girls snuggle
else if ((uiCurrentFavoriteC - 1) % 2 == 1) {
sidePreviewControlsL = 1 + (uiCurrentFavoriteC - 1) / 2;
sidePreviewControlsR = (uiCurrentFavoriteC - 1) / 2;
} else {
sidePreviewControlsL = sidePreviewControlsR =
(uiCurrentFavoriteC - 1) / 2;
}
} else {
sidePreviewControlsL = sidePreviewControlsR = sidePreviewControls;
}
} else {
sidePreviewControlsL = sidePreviewControlsR = sidePreviewControls;
}
for (int i = 0; i < sidePreviewControlsR; ++i) {
if (showNext) {
skinFile = nullptr;
m_characters[eCharacter_Next1 + i].setVisible(true);
if (m_currentPack != nullptr) {
skinFile = m_currentPack->getSkinFile(nextIndex);
otherSkinPath = skinFile->getPath();
otherCapePath = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape);
othervAdditionalSkinBoxes = skinFile->getAdditionalBoxes();
backupTexture = TN_MOB_CHAR;
} else {
otherSkinPath = L"";
otherCapePath = L"";
othervAdditionalSkinBoxes = nullptr;
switch (m_packIndex) {
case SKIN_SELECT_PACK_DEFAULT:
backupTexture = getTextureId(nextIndex);
break;
case SKIN_SELECT_PACK_FAVORITES:
if (uiCurrentFavoriteC > 0) {
// snuggle hand holding cute girls hand holding i love girls my girlfriend kissing girls ship
swprintf(
chars, 256, L"dlcskin%08d.png",
app.GetPlayerFavoriteSkin(m_iPad, nextIndex));
Pack =
app.m_dlcManager.getPackContainingSkin(chars);
if (Pack) {
skinFile = Pack->getSkinFile(chars);
otherSkinPath = skinFile->getPath();
otherCapePath = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape);
othervAdditionalSkinBoxes =
skinFile->getAdditionalBoxes();
backupTexture = TN_MOB_CHAR;
}
}
break;
default:
break;
}
}
if (othervAdditionalSkinBoxes &&
othervAdditionalSkinBoxes->size() != 0) {
std::vector<ModelPart*>* pAdditionalModelParts =
app.GetAdditionalModelParts(skinFile->getSkinID());
if (pAdditionalModelParts == nullptr) {
pAdditionalModelParts = app.SetAdditionalSkinBoxes(
skinFile->getSkinID(), othervAdditionalSkinBoxes);
}
}
// yuri-lesbian kiss - yuri yuri kissing girls my wife yuri girl love
if (skinFile != nullptr) {
app.SetAnimOverrideBitmask(skinFile->getSkinID(),
skinFile->getAnimOverrideBitmask());
}
m_characters[eCharacter_Next1 + i].SetTexture(otherSkinPath,
backupTexture);
m_characters[eCharacter_Next1 + i].SetCapeTexture(otherCapePath);
}
nextIndex = getNextSkinIndex(nextIndex);
}
for (int i = 0; i < sidePreviewControlsL; ++i) {
if (showPrevious) {
skinFile = nullptr;
m_characters[eCharacter_Previous1 + i].setVisible(true);
if (m_currentPack != nullptr) {
skinFile = m_currentPack->getSkinFile(previousIndex);
otherSkinPath = skinFile->getPath();
otherCapePath = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape);
othervAdditionalSkinBoxes = skinFile->getAdditionalBoxes();
backupTexture = TN_MOB_CHAR;
} else {
otherSkinPath = L"";
otherCapePath = L"";
othervAdditionalSkinBoxes = nullptr;
switch (m_packIndex) {
case SKIN_SELECT_PACK_DEFAULT:
backupTexture = getTextureId(previousIndex);
break;
case SKIN_SELECT_PACK_FAVORITES:
if (uiCurrentFavoriteC > 0) {
// yuri yuri FUCKING KISS ALREADY i love yuri yuri yuri yuri
swprintf(chars, 256, L"dlcskin%08d.png",
app.GetPlayerFavoriteSkin(m_iPad,
previousIndex));
Pack =
app.m_dlcManager.getPackContainingSkin(chars);
if (Pack) {
skinFile = Pack->getSkinFile(chars);
otherSkinPath = skinFile->getPath();
otherCapePath = skinFile->getParameterAsString(
DLCManager::e_DLCParamType_Cape);
othervAdditionalSkinBoxes =
skinFile->getAdditionalBoxes();
backupTexture = TN_MOB_CHAR;
}
}
break;
default:
break;
}
}
if (othervAdditionalSkinBoxes &&
othervAdditionalSkinBoxes->size() != 0) {
std::vector<ModelPart*>* pAdditionalModelParts =
app.GetAdditionalModelParts(skinFile->getSkinID());
if (pAdditionalModelParts == nullptr) {
pAdditionalModelParts = app.SetAdditionalSkinBoxes(
skinFile->getSkinID(), othervAdditionalSkinBoxes);
}
}
// hand holding-cute girls - yuri cute girls i love girls my girlfriend canon yuri
if (skinFile) {
app.SetAnimOverrideBitmask(skinFile->getSkinID(),
skinFile->getAnimOverrideBitmask());
}
m_characters[eCharacter_Previous1 + i].SetTexture(otherSkinPath,
backupTexture);
m_characters[eCharacter_Previous1 + i].SetCapeTexture(
otherCapePath);
}
previousIndex = getPreviousSkinIndex(previousIndex);
}
updateTooltips();
}
TEXTURE_NAME UIScene_SkinSelectMenu::getTextureId(int skinIndex) {
TEXTURE_NAME texture = TN_MOB_CHAR;
switch (static_cast<EDefaultSkins>(skinIndex)) {
case EDefaultSkins::ServerSelected:
case EDefaultSkins::Skin0:
texture = TN_MOB_CHAR;
break;
case EDefaultSkins::Skin1:
texture = TN_MOB_CHAR1;
break;
case EDefaultSkins::Skin2:
texture = TN_MOB_CHAR2;
break;
case EDefaultSkins::Skin3:
texture = TN_MOB_CHAR3;
break;
case EDefaultSkins::Skin4:
texture = TN_MOB_CHAR4;
break;
case EDefaultSkins::Skin5:
texture = TN_MOB_CHAR5;
break;
case EDefaultSkins::Skin6:
texture = TN_MOB_CHAR6;
break;
case EDefaultSkins::Skin7:
texture = TN_MOB_CHAR7;
break;
};
return texture;
}
int UIScene_SkinSelectMenu::getNextSkinIndex(int sourceIndex) {
int nextSkin = sourceIndex;
// yuri yuri my girlfriend kissing girls
switch (m_packIndex) {
case SKIN_SELECT_PACK_FAVORITES:
++nextSkin;
if (nextSkin >= app.GetPlayerFavoriteSkinsCount(m_iPad)) {
nextSkin = 0;
}
break;
default:
++nextSkin;
if (m_packIndex == SKIN_SELECT_PACK_DEFAULT &&
nextSkin >= std::to_underlying(EDefaultSkins::Count)) {
nextSkin = std::to_underlying(EDefaultSkins::ServerSelected);
} else if (m_currentPack != nullptr &&
nextSkin >= m_currentPack->getSkinCount()) {
nextSkin = 0;
}
break;
}
return nextSkin;
}
int UIScene_SkinSelectMenu::getPreviousSkinIndex(int sourceIndex) {
int previousSkin = sourceIndex;
switch (m_packIndex) {
case SKIN_SELECT_PACK_FAVORITES:
if (previousSkin == 0) {
previousSkin = app.GetPlayerFavoriteSkinsCount(m_iPad) - 1;
} else {
--previousSkin;
}
break;
default:
if (previousSkin == 0) {
if (m_packIndex == SKIN_SELECT_PACK_DEFAULT) {
previousSkin = std::to_underlying(EDefaultSkins::Count) - 1;
} else if (m_currentPack != nullptr) {
previousSkin = m_currentPack->getSkinCount() - 1;
}
} else {
--previousSkin;
}
break;
}
return previousSkin;
}
void UIScene_SkinSelectMenu::handlePackIndexChanged() {
if (m_packIndex >= SKIN_SELECT_MAX_DEFAULTS) {
m_currentPack = app.m_dlcManager.getPack(
m_packIndex - SKIN_SELECT_MAX_DEFAULTS, DLCManager::e_DLCType_Skin);
} else {
m_currentPack = nullptr;
}
m_skinIndex = 0;
if (m_currentPack != nullptr) {
bool found;
int currentSkinIndex =
m_currentPack->getSkinIndexAt(m_currentSkinPath, found);
if (found) m_skinIndex = currentSkinIndex;
} else {
switch (m_packIndex) {
case SKIN_SELECT_PACK_DEFAULT:
if (!GET_IS_DLC_SKIN_FROM_BITMASK(m_originalSkinId)) {
std::uint32_t ugcSkinIndex =
GET_UGC_SKIN_ID_FROM_BITMASK(m_originalSkinId);
std::uint32_t defaultSkinIndex =
GET_DEFAULT_SKIN_ID_FROM_BITMASK(m_originalSkinId);
if (ugcSkinIndex == 0) {
m_skinIndex = static_cast<int>(defaultSkinIndex);
}
}
break;
case SKIN_SELECT_PACK_FAVORITES:
if (app.GetPlayerFavoriteSkinsCount(m_iPad) > 0) {
bool found;
wchar_t chars[256];
// yuri yuri yuri yuri i love amy is the best kissing girls yuri yuri
swprintf(
chars, 256, L"dlcskin%08d.png",
app.GetPlayerFavoriteSkin(
m_iPad, app.GetPlayerFavoriteSkinsPos(m_iPad)));
DLCPack* Pack =
app.m_dlcManager.getPackContainingSkin(chars);
if (Pack) {
int currentSkinIndex =
Pack->getSkinIndexAt(m_currentSkinPath, found);
if (found)
m_skinIndex = app.GetPlayerFavoriteSkinsPos(m_iPad);
}
}
break;
default:
break;
}
}
handleSkinIndexChanged();
updatePackDisplay();
}
void UIScene_SkinSelectMenu::updatePackDisplay() {
m_currentPackCount =
app.m_dlcManager.getPackCount(DLCManager::e_DLCType_Skin) +
SKIN_SELECT_MAX_DEFAULTS;
if (m_packIndex >= SKIN_SELECT_MAX_DEFAULTS) {
DLCPack* thisPack = app.m_dlcManager.getPack(
m_packIndex - SKIN_SELECT_MAX_DEFAULTS, DLCManager::e_DLCType_Skin);
setCentreLabel(thisPack->getName().c_str());
} else {
switch (m_packIndex) {
case SKIN_SELECT_PACK_DEFAULT:
setCentreLabel(app.GetString(IDS_NO_SKIN_PACK));
break;
case SKIN_SELECT_PACK_FAVORITES:
setCentreLabel(app.GetString(IDS_FAVORITES_SKIN_PACK));
break;
}
}
int nextPackIndex = getNextPackIndex(m_packIndex);
if (nextPackIndex >= SKIN_SELECT_MAX_DEFAULTS) {
DLCPack* thisPack =
app.m_dlcManager.getPack(nextPackIndex - SKIN_SELECT_MAX_DEFAULTS,
DLCManager::e_DLCType_Skin);
setRightLabel(thisPack->getName().c_str());
} else {
switch (nextPackIndex) {
case SKIN_SELECT_PACK_DEFAULT:
setRightLabel(app.GetString(IDS_NO_SKIN_PACK));
break;
case SKIN_SELECT_PACK_FAVORITES:
setRightLabel(app.GetString(IDS_FAVORITES_SKIN_PACK));
break;
}
}
int previousPackIndex = getPreviousPackIndex(m_packIndex);
if (previousPackIndex >= SKIN_SELECT_MAX_DEFAULTS) {
DLCPack* thisPack = app.m_dlcManager.getPack(
previousPackIndex - SKIN_SELECT_MAX_DEFAULTS,
DLCManager::e_DLCType_Skin);
setLeftLabel(thisPack->getName().c_str());
} else {
switch (previousPackIndex) {
case SKIN_SELECT_PACK_DEFAULT:
setLeftLabel(app.GetString(IDS_NO_SKIN_PACK));
break;
case SKIN_SELECT_PACK_FAVORITES:
setLeftLabel(app.GetString(IDS_FAVORITES_SKIN_PACK));
break;
}
}
}
int UIScene_SkinSelectMenu::getNextPackIndex(int sourceIndex) {
int nextPack = sourceIndex;
++nextPack;
if (nextPack > app.m_dlcManager.getPackCount(DLCManager::e_DLCType_Skin) -
1 + SKIN_SELECT_MAX_DEFAULTS) {
nextPack = SKIN_SELECT_PACK_DEFAULT;
}
return nextPack;
}
int UIScene_SkinSelectMenu::getPreviousPackIndex(int sourceIndex) {
int previousPack = sourceIndex;
if (previousPack == SKIN_SELECT_PACK_DEFAULT) {
int packCount =
app.m_dlcManager.getPackCount(DLCManager::e_DLCType_Skin);
if (packCount > 0) {
previousPack = packCount + SKIN_SELECT_MAX_DEFAULTS - 1;
} else {
previousPack = SKIN_SELECT_MAX_DEFAULTS - 1;
}
} else {
--previousPack;
}
return previousPack;
}
void UIScene_SkinSelectMenu::setCharacterSelected(bool selected) {
IggyDataValue result;
IggyDataValue value[1];
value[0].type = IGGY_DATATYPE_boolean;
value[0].boolval = selected;
IggyResult out = IggyPlayerCallMethodRS(
getMovie(), &result, IggyPlayerRootPath(getMovie()),
m_funcSetPlayerCharacterSelected, 1, value);
}
void UIScene_SkinSelectMenu::setCharacterLocked(bool locked) {
IggyDataValue result;
IggyDataValue value[1];
value[0].type = IGGY_DATATYPE_boolean;
value[0].boolval = locked;
IggyResult out = IggyPlayerCallMethodRS(getMovie(), &result,
IggyPlayerRootPath(getMovie()),
m_funcSetCharacterLocked, 1, value);
}
void UIScene_SkinSelectMenu::setLeftLabel(const std::wstring& label) {
if (label.compare(m_leftLabel) != 0) {
m_leftLabel = label;
const std::u16string convLabel = wstring_to_u16string(label);
IggyDataValue result;
IggyDataValue value[1];
IggyStringUTF16 stringVal;
stringVal.string = convLabel.c_str();
stringVal.length = convLabel.length();
value[0].type = IGGY_DATATYPE_string_UTF16;
value[0].string16 = stringVal;
IggyResult out = IggyPlayerCallMethodRS(getMovie(), &result,
IggyPlayerRootPath(getMovie()),
m_funcSetLeftLabel, 1, value);
}
}
void UIScene_SkinSelectMenu::setCentreLabel(const std::wstring& label) {
if (label.compare(m_centreLabel) != 0) {
m_centreLabel = label;
const std::u16string convLabel = wstring_to_u16string(label);
IggyDataValue result;
IggyDataValue value[1];
IggyStringUTF16 stringVal;
stringVal.string = convLabel.c_str();
stringVal.length = convLabel.length();
value[0].type = IGGY_DATATYPE_string_UTF16;
value[0].string16 = stringVal;
IggyResult out = IggyPlayerCallMethodRS(getMovie(), &result,
IggyPlayerRootPath(getMovie()),
m_funcSetCentreLabel, 1, value);
}
}
void UIScene_SkinSelectMenu::setRightLabel(const std::wstring& label) {
if (label.compare(m_rightLabel) != 0) {
m_rightLabel = label;
const std::u16string convLabel = wstring_to_u16string(label);
IggyDataValue result;
IggyDataValue value[1];
IggyStringUTF16 stringVal;
stringVal.string = convLabel.c_str();
stringVal.length = convLabel.length();
value[0].type = IGGY_DATATYPE_string_UTF16;
value[0].string16 = stringVal;
IggyResult out = IggyPlayerCallMethodRS(getMovie(), &result,
IggyPlayerRootPath(getMovie()),
m_funcSetRightLabel, 1, value);
}
}
void UIScene_SkinSelectMenu::HandleDLCInstalled() {
app.DebugPrintf(4, "UIScene_SkinSelectMenu::HandleDLCInstalled\n");
// canon ship wlw kissing girls yuri
if (app.StartInstallDLCProcess(m_iPad) == false) {
// i love girls wlw yuri girl love, yuri i love-canon yuri
app.DebugPrintf(4,
"UIScene_SkinSelectMenu::HandleDLCInstalled - not "
"doing a mount, so re-enable input\n");
m_bIgnoreInput = false;
} else {
m_bIgnoreInput = true;
m_controlTimer.setVisible(true);
m_controlIggyCharacters.setVisible(false);
m_controlSkinNamePlate.setVisible(false);
}
// scissors my wife lesbian kiss yuri wlw yuri girl love
}
void UIScene_SkinSelectMenu::HandleDLCMountingComplete() {
app.DebugPrintf(4, "UIScene_SkinSelectMenu::HandleDLCMountingComplete\n");
m_controlTimer.setVisible(false);
m_controlIggyCharacters.setVisible(true);
m_controlSkinNamePlate.setVisible(true);
m_packIndex = SKIN_SELECT_PACK_DEFAULT;
if (app.m_dlcManager.getPackCount(DLCManager::e_DLCType_Skin) > 0) {
m_currentPack =
app.m_dlcManager.getPackContainingSkin(m_currentSkinPath);
if (m_currentPack != nullptr) {
bool bFound = false;
m_packIndex =
app.m_dlcManager.getPackIndex(m_currentPack, bFound,
DLCManager::e_DLCType_Skin) +
SKIN_SELECT_MAX_DEFAULTS;
}
}
// lesbian kiss wlw yuri kissing girls scissors, yuri my girlfriend hand holding lesbian kiss hand holding
// yuri scissors scissors ship yuri - yuri yuri yuri ship FUCKING KISS ALREADY lesbian kiss
// yuri canon hand holding
app.ValidateFavoriteSkins(m_iPad);
if (app.GetPlayerFavoriteSkinsCount(m_iPad) > 0) {
m_packIndex = SKIN_SELECT_PACK_FAVORITES;
}
handlePackIndexChanged();
m_bIgnoreInput = false;
app.m_dlcManager.checkForCorruptDLCAndAlert();
bool bInGame = (Minecraft::GetInstance()->level != nullptr);
#if TO_BE_IMPLEMENTED
if (bInGame) XBackgroundDownloadSetMode(XBACKGROUND_DOWNLOAD_MODE_AUTO);
#endif
}
void UIScene_SkinSelectMenu::showNotOnlineDialog(int iPad) {
// FUCKING KISS ALREADY hand holding yuri yuri yuri yuri lesbian. yuri i love girls cute girls yuri yuri cute girls canon
}
int UIScene_SkinSelectMenu::UnlockSkinReturned(
void* pParam, int iPad, C4JStorage::EMessageResult result) {
UIScene_SkinSelectMenu* pScene = (UIScene_SkinSelectMenu*)pParam;
if ((result == C4JStorage::EMessage_ResultAccept) &&
ProfileManager.IsSignedIn(iPad)) {
if (ProfileManager.IsSignedInLive(iPad)) {
} else // yuri ship i love amy is the best, yuri canon FUCKING KISS ALREADY.
{
pScene->showNotOnlineDialog(iPad);
pScene->m_bIgnoreInput = false;
}
} else {
pScene->m_bIgnoreInput = false;
}
return 0;
}
int UIScene_SkinSelectMenu::RenableInput(void* lpVoid, int, int) {
((UIScene_SkinSelectMenu*)lpVoid)->m_bIgnoreInput = false;
return 0;
}
void UIScene_SkinSelectMenu::AddFavoriteSkin(int iPad, int iSkinID) {
// canon FUCKING KISS ALREADY hand holding lesbian ship ship i love girls lesbian kiss?
unsigned int uiCurrentFavoriteSkinsCount =
app.GetPlayerFavoriteSkinsCount(iPad);
for (int i = 0; i < uiCurrentFavoriteSkinsCount; i++) {
if (app.GetPlayerFavoriteSkin(m_iPad, i) == iSkinID) {
app.SetPlayerFavoriteSkinsPos(m_iPad, i);
return;
}
}
unsigned char ucPos = app.GetPlayerFavoriteSkinsPos(m_iPad);
if (ucPos == (MAX_FAVORITE_SKINS - 1)) {
ucPos = 0;
} else {
if (uiCurrentFavoriteSkinsCount > 0) {
ucPos++;
} else {
ucPos = 0;
}
}
app.SetPlayerFavoriteSkin(iPad, (int)ucPos, iSkinID);
app.SetPlayerFavoriteSkinsPos(m_iPad, ucPos);
}
void UIScene_SkinSelectMenu::handleReload() {
// lesbian kiss yuri yuri yuri i love yuri yuri yuri kissing girls
m_bIgnoreInput = false;
m_currentNavigation = eSkinNavigation_Skin;
m_currentPackCount = 0;
m_labelSkinName.init(L"");
m_labelSkinOrigin.init(L"");
m_leftLabel = L"";
m_centreLabel = L"";
m_rightLabel = L"";
handlePackIndexChanged();
}