//
// GJSmartTemplate::applyTransformationsForType from 0x1000079ac to 0x100007adc (304 bytes)
//
// 3 xrefs:
// > GJSmartBlockPreview::addTemplateGuide_1 @ 0x100008dd4
// > GJSmartBlockPreview::addTemplateGuide_1 @ 0x100008f0c
// > EditorUI::createPrefab @ 0x1003f244c
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __fastcall GJSmartTemplate::applyTransformationsForType(SmartBlockType a1, cocos2d::CCSprite *a2)
{
int v3; // w8
if ( a1 > WideSlope6 )
{
if ( (unsigned int)(a1 - 71) > 5 )
{
if ( (unsigned int)(a1 - 67) < 2 )
goto LABEL_19;
if ( (unsigned int)(a1 - 69) >= 2 )
return;
cocos2d::CCSprite::setFlipX(a2, 1);
}
else
{
v3 = 1 << (a1 - 71);
if ( (v3 & 3) != 0 )
goto LABEL_18;
if ( (v3 & 0xC) == 0 )
cocos2d::CCSprite::setFlipY(a2, 1);
}
((void (__fastcall *)(cocos2d::CCSprite *, float))a2->setRotation)(a2, -90.0);
return;
}
if ( a1 > WideSlope2 )
{
if ( (unsigned int)(a1 - 56) < 2 )
{
cocos2d::CCSprite::setFlipX(a2, 1);
}
else if ( (unsigned int)(a1 - 65) < 2 )
{
cocos2d::CCSprite::setFlipY(a2, 1);
}
return;
}
switch ( a1 )
{
case NormalSlope2:
LABEL_18:
((void (__fastcall *)(cocos2d::CCSprite *, float))a2->setRotation)(a2, 90.0);
return;
case NormalSlope3:
((void (__fastcall *)(cocos2d::CCSprite *, float))a2->setRotation)(a2, 270.0);
return;
case NormalSlope4:
LABEL_19:
((void (__fastcall *)(cocos2d::CCSprite *, float))a2->setRotation)(a2, 180.0);
break;
}
}