mirror of
https://github.com/RHeavenStudioPlus/HeavenStudioPlus.git
synced 2024-11-22 17:45:16 +00:00
Crop Stomp: Dots bg
This commit is contained in:
parent
93bbbd0ee2
commit
71838124c9
3 changed files with 192 additions and 2 deletions
|
@ -261,6 +261,88 @@ MonoBehaviour:
|
|||
handleType: 0
|
||||
leftHandleLocalPosition: {x: 0, y: -1, z: 0}
|
||||
rightHandleLocalPosition: {x: -0, y: 1, z: -0}
|
||||
--- !u!1 &2196892543300460367
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 705117715505720769}
|
||||
- component: {fileID: 8392844652767620313}
|
||||
m_Layer: 0
|
||||
m_Name: Dots
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &705117715505720769
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2196892543300460367}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 1.34, z: 0}
|
||||
m_LocalScale: {x: 0.75, y: 0.75, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 5813499711186931250}
|
||||
m_RootOrder: 3
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &8392844652767620313
|
||||
SpriteRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 2196892543300460367}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 1
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 1
|
||||
m_ReflectionProbeUsage: 1
|
||||
m_RayTracingMode: 0
|
||||
m_RayTraceProcedural: 0
|
||||
m_RenderingLayerMask: 1
|
||||
m_RendererPriority: 0
|
||||
m_Materials:
|
||||
- {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0}
|
||||
m_StaticBatchInfo:
|
||||
firstSubMesh: 0
|
||||
subMeshCount: 0
|
||||
m_StaticBatchRoot: {fileID: 0}
|
||||
m_ProbeAnchor: {fileID: 0}
|
||||
m_LightProbeVolumeOverride: {fileID: 0}
|
||||
m_ScaleInLightmap: 1
|
||||
m_ReceiveGI: 1
|
||||
m_PreserveUVs: 0
|
||||
m_IgnoreNormalsForChartDetection: 0
|
||||
m_ImportantGI: 0
|
||||
m_StitchLightmapSeams: 1
|
||||
m_SelectedEditorRenderState: 0
|
||||
m_MinimumChartSize: 4
|
||||
m_AutoUVMaxDistance: 0.5
|
||||
m_AutoUVMaxAngle: 89
|
||||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: -100
|
||||
m_Sprite: {fileID: 21300000, guid: 00958a184f8b38940869d44305381337, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 2
|
||||
m_Size: {x: 120, y: 12.8}
|
||||
m_AdaptiveModeThreshold: 0.5
|
||||
m_SpriteTileMode: 0
|
||||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!1 &2339041431090773305
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -1076,7 +1158,7 @@ Transform:
|
|||
m_LocalScale: {x: 4.5, y: 4.5, z: 5}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 5813499711186931250}
|
||||
m_RootOrder: 3
|
||||
m_RootOrder: 4
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &6072388044625575886
|
||||
SpriteRenderer:
|
||||
|
@ -1242,6 +1324,7 @@ Transform:
|
|||
- {fileID: 3229117913716202416}
|
||||
- {fileID: 6378453749366738950}
|
||||
- {fileID: 5722211921049515452}
|
||||
- {fileID: 705117715505720769}
|
||||
- {fileID: 9053856824134827426}
|
||||
- {fileID: 5813499711658895220}
|
||||
m_Father: {fileID: 0}
|
||||
|
@ -1268,6 +1351,7 @@ MonoBehaviour:
|
|||
farmerTrans: {fileID: 2890674062888421961}
|
||||
grass: {fileID: 6072388044625575886}
|
||||
grassTrans: {fileID: 9053856824134827426}
|
||||
dotsTrans: {fileID: 705117715505720769}
|
||||
scrollingHolder: {fileID: 3229117913716202416}
|
||||
veggieHolder: {fileID: 6205523899711794644}
|
||||
farmer: {fileID: 2943047049103139379}
|
||||
|
@ -1302,7 +1386,7 @@ Transform:
|
|||
m_LocalScale: {x: 18.9426, y: 11.7704, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 5813499711186931250}
|
||||
m_RootOrder: 4
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &5813499711658895221
|
||||
SpriteRenderer:
|
||||
|
|
96
Assets/Resources/Sprites/Games/CropStomp/bg.png.meta
Normal file
96
Assets/Resources/Sprites/Games/CropStomp/bg.png.meta
Normal file
|
@ -0,0 +1,96 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 00958a184f8b38940869d44305381337
|
||||
TextureImporter:
|
||||
internalIDToNameTable: []
|
||||
externalObjects: {}
|
||||
serializedVersion: 11
|
||||
mipmaps:
|
||||
mipMapMode: 0
|
||||
enableMipMap: 0
|
||||
sRGBTexture: 1
|
||||
linearTexture: 0
|
||||
fadeOut: 0
|
||||
borderMipMap: 0
|
||||
mipMapsPreserveCoverage: 0
|
||||
alphaTestReferenceValue: 0.5
|
||||
mipMapFadeDistanceStart: 1
|
||||
mipMapFadeDistanceEnd: 3
|
||||
bumpmap:
|
||||
convertToNormalMap: 0
|
||||
externalNormalMap: 0
|
||||
heightScale: 0.25
|
||||
normalMapFilter: 0
|
||||
isReadable: 0
|
||||
streamingMipmaps: 0
|
||||
streamingMipmapsPriority: 0
|
||||
vTOnly: 0
|
||||
grayScaleToAlpha: 0
|
||||
generateCubemap: 6
|
||||
cubemapConvolution: 0
|
||||
seamlessCubemap: 0
|
||||
textureFormat: 1
|
||||
maxTextureSize: 2048
|
||||
textureSettings:
|
||||
serializedVersion: 2
|
||||
filterMode: 1
|
||||
aniso: 1
|
||||
mipBias: 0
|
||||
wrapU: 1
|
||||
wrapV: 1
|
||||
wrapW: 1
|
||||
nPOTScale: 0
|
||||
lightmap: 0
|
||||
compressionQuality: 50
|
||||
spriteMode: 1
|
||||
spriteExtrude: 1
|
||||
spriteMeshType: 1
|
||||
alignment: 0
|
||||
spritePivot: {x: 0.5, y: 0.5}
|
||||
spritePixelsToUnits: 100
|
||||
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
|
||||
spriteGenerateFallbackPhysicsShape: 1
|
||||
alphaUsage: 1
|
||||
alphaIsTransparency: 1
|
||||
spriteTessellationDetail: -1
|
||||
textureType: 8
|
||||
textureShape: 1
|
||||
singleChannelComponent: 0
|
||||
flipbookRows: 1
|
||||
flipbookColumns: 1
|
||||
maxTextureSizeSet: 0
|
||||
compressionQualitySet: 0
|
||||
textureFormatSet: 0
|
||||
ignorePngGamma: 0
|
||||
applyGammaDecoding: 0
|
||||
platformSettings:
|
||||
- serializedVersion: 3
|
||||
buildTarget: DefaultTexturePlatform
|
||||
maxTextureSize: 2048
|
||||
resizeAlgorithm: 0
|
||||
textureFormat: -1
|
||||
textureCompression: 1
|
||||
compressionQuality: 50
|
||||
crunchedCompression: 0
|
||||
allowsAlphaSplitting: 0
|
||||
overridden: 0
|
||||
androidETC2FallbackOverride: 0
|
||||
forceMaximumCompressionQuality_BC6H_BC7: 0
|
||||
spriteSheet:
|
||||
serializedVersion: 2
|
||||
sprites: []
|
||||
outline: []
|
||||
physicsShape: []
|
||||
bones: []
|
||||
spriteID: 5e97eb03825dee720800000000000000
|
||||
internalID: 0
|
||||
vertices: []
|
||||
indices:
|
||||
edges: []
|
||||
weights: []
|
||||
secondaryTextures: []
|
||||
spritePackingTag:
|
||||
pSDRemoveMatte: 0
|
||||
pSDShowRemoveMatteOption: 0
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -16,6 +16,7 @@ namespace RhythmHeavenMania.Games.CropStomp
|
|||
|
||||
float scrollRate => stepDistance / (Conductor.instance.secPerBeat * 2f / Conductor.instance.musicSource.pitch);
|
||||
float grassWidth;
|
||||
float dotsWidth = 19.2f;
|
||||
|
||||
private float newBeat = -1f; // So that marching can happen on beat 0.
|
||||
private float marchStartBeat = -1f;
|
||||
|
@ -35,6 +36,7 @@ namespace RhythmHeavenMania.Games.CropStomp
|
|||
public Transform farmerTrans;
|
||||
public SpriteRenderer grass;
|
||||
public Transform grassTrans;
|
||||
public Transform dotsTrans;
|
||||
public Transform scrollingHolder;
|
||||
public Transform veggieHolder;
|
||||
public Farmer farmer;
|
||||
|
@ -187,6 +189,14 @@ namespace RhythmHeavenMania.Games.CropStomp
|
|||
newGrassX = (newGrassX % (grassWidth * 4.5f));
|
||||
|
||||
grassTrans.localPosition = new Vector3(newGrassX, grassPos.y, grassPos.z);
|
||||
|
||||
// Dots scroll
|
||||
var dotsPos = dotsTrans.localPosition;
|
||||
|
||||
var newDotsX = dotsPos.x + (scrollRate * Time.deltaTime);
|
||||
newDotsX = (newDotsX % dotsWidth);
|
||||
|
||||
dotsTrans.localPosition = new Vector3(newDotsX, dotsPos.y, dotsPos.z);
|
||||
}
|
||||
|
||||
private void LateUpdate()
|
||||
|
|
Loading…
Reference in a new issue