Recolorable Dazzles
idk how github works lol
This commit is contained in:
parent
4112cc9e56
commit
18e4df042a
91
Assets/Bundled/Games/TheDazzles/Sprites/boxexterior.mat
Normal file
91
Assets/Bundled/Games/TheDazzles/Sprites/boxexterior.mat
Normal file
|
@ -0,0 +1,91 @@
|
||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!21 &2100000
|
||||||
|
Material:
|
||||||
|
serializedVersion: 8
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_Name: boxexterior
|
||||||
|
m_Shader: {fileID: 4800000, guid: b4cada49e3bbaee4b96deed8a436d7fd, type: 3}
|
||||||
|
m_ValidKeywords: []
|
||||||
|
m_InvalidKeywords: []
|
||||||
|
m_LightmapFlags: 4
|
||||||
|
m_EnableInstancingVariants: 0
|
||||||
|
m_DoubleSidedGI: 0
|
||||||
|
m_CustomRenderQueue: -1
|
||||||
|
stringTagMap: {}
|
||||||
|
disabledShaderPasses: []
|
||||||
|
m_SavedProperties:
|
||||||
|
serializedVersion: 3
|
||||||
|
m_TexEnvs:
|
||||||
|
- _BumpMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailAlbedoMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailMask:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailNormalMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _EmissionMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MainTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MetallicGlossMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _OcclusionMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _ParallaxMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
m_Ints: []
|
||||||
|
m_Floats:
|
||||||
|
- _BumpScale: 1
|
||||||
|
- _ColorMask: 15
|
||||||
|
- _Cutoff: 0.5
|
||||||
|
- _DetailNormalMapScale: 1
|
||||||
|
- _DstBlend: 0
|
||||||
|
- _GlossMapScale: 1
|
||||||
|
- _Glossiness: 0.5
|
||||||
|
- _GlossyReflections: 1
|
||||||
|
- _Metallic: 0
|
||||||
|
- _Mode: 0
|
||||||
|
- _OcclusionStrength: 1
|
||||||
|
- _Parallax: 0.02
|
||||||
|
- _SmoothnessTextureChannel: 0
|
||||||
|
- _SpecularHighlights: 1
|
||||||
|
- _SrcBlend: 1
|
||||||
|
- _Stencil: 0
|
||||||
|
- _StencilComp: 8
|
||||||
|
- _StencilOp: 0
|
||||||
|
- _StencilReadMask: 255
|
||||||
|
- _StencilWriteMask: 255
|
||||||
|
- _UVSec: 0
|
||||||
|
- _UseUIAlphaClip: 0
|
||||||
|
- _ZWrite: 1
|
||||||
|
m_Colors:
|
||||||
|
- _AddColor: {r: 0.6117647, g: 0.99607843, b: 0.9647059, a: 0}
|
||||||
|
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
- _ColorAlpha: {r: 0.6117647, g: 0.99607843, b: 0.9647059, a: 1}
|
||||||
|
- _ColorBravo: {r: 0.44705883, g: 0.15294118, b: 0.6745098, a: 1}
|
||||||
|
- _ColorDelta: {r: 0.44705883, g: 0.15294118, b: 0.6745098, a: 1}
|
||||||
|
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
||||||
|
m_BuildTextureStacks: []
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: eeab50c60cb7b1942824fee6e2b7d18e
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 2100000
|
||||||
|
userData:
|
||||||
|
assetBundleName: ntrboxshow/common
|
||||||
|
assetBundleVariant:
|
91
Assets/Bundled/Games/TheDazzles/Sprites/boxinterior.mat
Normal file
91
Assets/Bundled/Games/TheDazzles/Sprites/boxinterior.mat
Normal file
|
@ -0,0 +1,91 @@
|
||||||
|
%YAML 1.1
|
||||||
|
%TAG !u! tag:unity3d.com,2011:
|
||||||
|
--- !u!21 &2100000
|
||||||
|
Material:
|
||||||
|
serializedVersion: 8
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_Name: boxinterior
|
||||||
|
m_Shader: {fileID: 4800000, guid: ff54fed5718ccc543808dec1f266d1c8, type: 3}
|
||||||
|
m_ValidKeywords: []
|
||||||
|
m_InvalidKeywords: []
|
||||||
|
m_LightmapFlags: 4
|
||||||
|
m_EnableInstancingVariants: 0
|
||||||
|
m_DoubleSidedGI: 0
|
||||||
|
m_CustomRenderQueue: -1
|
||||||
|
stringTagMap: {}
|
||||||
|
disabledShaderPasses: []
|
||||||
|
m_SavedProperties:
|
||||||
|
serializedVersion: 3
|
||||||
|
m_TexEnvs:
|
||||||
|
- _BumpMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailAlbedoMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailMask:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _DetailNormalMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _EmissionMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MainTex:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _MetallicGlossMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _OcclusionMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
- _ParallaxMap:
|
||||||
|
m_Texture: {fileID: 0}
|
||||||
|
m_Scale: {x: 1, y: 1}
|
||||||
|
m_Offset: {x: 0, y: 0}
|
||||||
|
m_Ints: []
|
||||||
|
m_Floats:
|
||||||
|
- _BumpScale: 1
|
||||||
|
- _ColorMask: 15
|
||||||
|
- _Cutoff: 0.5
|
||||||
|
- _DetailNormalMapScale: 1
|
||||||
|
- _DstBlend: 0
|
||||||
|
- _GlossMapScale: 1
|
||||||
|
- _Glossiness: 0.5
|
||||||
|
- _GlossyReflections: 1
|
||||||
|
- _Metallic: 0
|
||||||
|
- _Mode: 0
|
||||||
|
- _OcclusionStrength: 1
|
||||||
|
- _Parallax: 0.02
|
||||||
|
- _SmoothnessTextureChannel: 0
|
||||||
|
- _SpecularHighlights: 1
|
||||||
|
- _SrcBlend: 1
|
||||||
|
- _Stencil: 0
|
||||||
|
- _StencilComp: 8
|
||||||
|
- _StencilOp: 0
|
||||||
|
- _StencilReadMask: 255
|
||||||
|
- _StencilWriteMask: 255
|
||||||
|
- _UVSec: 0
|
||||||
|
- _UseUIAlphaClip: 0
|
||||||
|
- _ZWrite: 1
|
||||||
|
m_Colors:
|
||||||
|
- _AddColor: {r: 0, g: 0, b: 0, a: 0}
|
||||||
|
- _Color: {r: 1, g: 1, b: 1, a: 1}
|
||||||
|
- _ColorAlpha: {r: 0, g: 0.7411765, b: 0.6745098, a: 1}
|
||||||
|
- _ColorBravo: {r: 0.25882354, g: 1, b: 0.9372549, a: 1}
|
||||||
|
- _ColorDelta: {r: 0, g: 0.87058824, b: 0.77254903, a: 1}
|
||||||
|
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
|
||||||
|
m_BuildTextureStacks: []
|
|
@ -0,0 +1,8 @@
|
||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 0024ecbb50d573d4888282a8edda5579
|
||||||
|
NativeFormatImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
mainObjectFileID: 2100000
|
||||||
|
userData:
|
||||||
|
assetBundleName: ntrboxshow/common
|
||||||
|
assetBundleVariant:
|
Binary file not shown.
Before Width: | Height: | Size: 903 KiB After Width: | Height: | Size: 969 KiB |
|
@ -280,7 +280,7 @@ TextureImporter:
|
||||||
maxTextureSize: 4096
|
maxTextureSize: 4096
|
||||||
resizeAlgorithm: 0
|
resizeAlgorithm: 0
|
||||||
textureFormat: -1
|
textureFormat: -1
|
||||||
textureCompression: 1
|
textureCompression: 2
|
||||||
compressionQuality: 50
|
compressionQuality: 50
|
||||||
crunchedCompression: 1
|
crunchedCompression: 1
|
||||||
allowsAlphaSplitting: 0
|
allowsAlphaSplitting: 0
|
||||||
|
@ -1695,9 +1695,9 @@ TextureImporter:
|
||||||
name: dazzles_65
|
name: dazzles_65
|
||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 95
|
x: 96
|
||||||
y: 85
|
y: 85
|
||||||
width: 675
|
width: 674
|
||||||
height: 678
|
height: 678
|
||||||
alignment: 0
|
alignment: 0
|
||||||
pivot: {x: 0.5, y: 0.5}
|
pivot: {x: 0.5, y: 0.5}
|
||||||
|
@ -1758,10 +1758,10 @@ TextureImporter:
|
||||||
name: dazzles_68
|
name: dazzles_68
|
||||||
rect:
|
rect:
|
||||||
serializedVersion: 2
|
serializedVersion: 2
|
||||||
x: 825
|
x: 830
|
||||||
y: 79
|
y: 85
|
||||||
width: 139
|
width: 128
|
||||||
height: 139
|
height: 128
|
||||||
alignment: 0
|
alignment: 0
|
||||||
pivot: {x: 0.5, y: 0.5}
|
pivot: {x: 0.5, y: 0.5}
|
||||||
border: {x: 0, y: 0, z: 0, w: 0}
|
border: {x: 0, y: 0, z: 0, w: 0}
|
||||||
|
|
|
@ -115,6 +115,19 @@ namespace HeavenStudio.Games.Loaders
|
||||||
{
|
{
|
||||||
function = delegate { TheDazzles.instance.ForceHold(); },
|
function = delegate { TheDazzles.instance.ForceHold(); },
|
||||||
defaultLength = 0.5f
|
defaultLength = 0.5f
|
||||||
|
},
|
||||||
|
|
||||||
|
new GameAction("boxColor", "Background Colors")
|
||||||
|
{
|
||||||
|
function = delegate { var e = eventCaller.currentEntity; TheDazzles.instance.ChangeBoxColor(e["ext"], e["int"], e["wall"], e["roof"]); },
|
||||||
|
defaultLength = 0.5f,
|
||||||
|
parameters = new List<Param>()
|
||||||
|
{
|
||||||
|
new Param("ext", TheDazzles.defaultExteriorColor, "Exterior", "Set the color of the boxes' exterior."),
|
||||||
|
new Param("int", TheDazzles.defaultInteriorColor, "Interior", "Set the color of the boxes' interiors."),
|
||||||
|
new Param("wall", TheDazzles.defaultWallColor, "Walls", "Set the color of the boxes' walls."),
|
||||||
|
new Param("roof", TheDazzles.defaultRoofColor, "Roof", "Set the color of the boxes' roofs."),
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
new List<string>() {"ntr", "normal"},
|
new List<string>() {"ntr", "normal"},
|
||||||
|
@ -130,6 +143,46 @@ namespace HeavenStudio.Games
|
||||||
using Scripts_TheDazzles;
|
using Scripts_TheDazzles;
|
||||||
public class TheDazzles : Minigame
|
public class TheDazzles : Minigame
|
||||||
{
|
{
|
||||||
|
private static Color _defaultExteriorColor;
|
||||||
|
public static Color defaultExteriorColor
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
ColorUtility.TryParseHtmlString("#9CFEF6", out _defaultExteriorColor);
|
||||||
|
return _defaultExteriorColor;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static Color _defaultInteriorColor;
|
||||||
|
public static Color defaultInteriorColor
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
ColorUtility.TryParseHtmlString("#42FFEF", out _defaultInteriorColor);
|
||||||
|
return _defaultInteriorColor;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static Color _defaultWallColor;
|
||||||
|
public static Color defaultWallColor
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
ColorUtility.TryParseHtmlString("#00DEC5", out _defaultWallColor);
|
||||||
|
return _defaultWallColor;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static Color _defaultRoofColor;
|
||||||
|
public static Color defaultRoofColor
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
ColorUtility.TryParseHtmlString("#00BDAC", out _defaultRoofColor);
|
||||||
|
return _defaultRoofColor;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public struct PosesToPerform : IComparable<PosesToPerform>
|
public struct PosesToPerform : IComparable<PosesToPerform>
|
||||||
{
|
{
|
||||||
// override object.Equals
|
// override object.Equals
|
||||||
|
@ -235,6 +288,9 @@ namespace HeavenStudio.Games
|
||||||
[SerializeField] TheDazzlesGirl player;
|
[SerializeField] TheDazzlesGirl player;
|
||||||
[SerializeField] ParticleSystem poseEffect;
|
[SerializeField] ParticleSystem poseEffect;
|
||||||
[SerializeField] ParticleSystem starsEffect;
|
[SerializeField] ParticleSystem starsEffect;
|
||||||
|
[Header("RecolorMaterials")]
|
||||||
|
public Material interiorMat;
|
||||||
|
public Material exteriorMat;
|
||||||
|
|
||||||
public static PlayerInput.InputAction InputAction_TouchRelease =
|
public static PlayerInput.InputAction InputAction_TouchRelease =
|
||||||
new("NtrBoxshowTouchRelease", new int[] { IAEmptyCat, IAReleaseCat, IAEmptyCat },
|
new("NtrBoxshowTouchRelease", new int[] { IAEmptyCat, IAReleaseCat, IAEmptyCat },
|
||||||
|
@ -254,6 +310,10 @@ namespace HeavenStudio.Games
|
||||||
{
|
{
|
||||||
instance = this;
|
instance = this;
|
||||||
SetupBopRegion("theDazzles", "bop", "toggle");
|
SetupBopRegion("theDazzles", "bop", "toggle");
|
||||||
|
interiorMat.SetColor("_ColorAlpha", defaultRoofColor);
|
||||||
|
interiorMat.SetColor("_ColorBravo", defaultInteriorColor);
|
||||||
|
interiorMat.SetColor("_ColorDelta", defaultWallColor);
|
||||||
|
exteriorMat.SetColor("_AddColor", defaultExteriorColor);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void OnBeatPulse(double beat)
|
public override void OnBeatPulse(double beat)
|
||||||
|
@ -272,6 +332,7 @@ namespace HeavenStudio.Games
|
||||||
{
|
{
|
||||||
if (queuedPoses.Count > 0) queuedPoses.Clear();
|
if (queuedPoses.Count > 0) queuedPoses.Clear();
|
||||||
if (queuedCrouches.Count > 0) queuedCrouches.Clear();
|
if (queuedCrouches.Count > 0) queuedCrouches.Clear();
|
||||||
|
PersistColor(beat);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Update()
|
void Update()
|
||||||
|
@ -671,6 +732,29 @@ namespace HeavenStudio.Games
|
||||||
}
|
}
|
||||||
|
|
||||||
void Nothing(PlayerActionEvent caller) { }
|
void Nothing(PlayerActionEvent caller) { }
|
||||||
|
|
||||||
|
public void ChangeBoxColor(Color exterior, Color interior, Color walls, Color roof)
|
||||||
|
{
|
||||||
|
interiorMat.SetColor("_ColorAlpha", roof);
|
||||||
|
interiorMat.SetColor("_ColorBravo", interior);
|
||||||
|
interiorMat.SetColor("_ColorDelta", walls);
|
||||||
|
exteriorMat.SetColor("_AddColor", exterior);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void PersistColor(double beat)
|
||||||
|
{
|
||||||
|
var allEventsBeforeBeat = EventCaller.GetAllInGameManagerList("theDazzles", new string[] { "boxColor" }).FindAll(x => x.beat < beat);
|
||||||
|
if (allEventsBeforeBeat.Count > 0)
|
||||||
|
{
|
||||||
|
allEventsBeforeBeat.Sort((x, y) => x.beat.CompareTo(y.beat)); //just in case
|
||||||
|
var lastEvent = allEventsBeforeBeat[^1];
|
||||||
|
ChangeBoxColor(lastEvent["ext"], lastEvent["int"], lastEvent["wall"], lastEvent["roof"]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override void OnGameSwitch(double beat)
|
||||||
|
{
|
||||||
|
PersistColor(beat);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue