Added Kenney Art, updated some code to use art better
This commit is contained in:
parent
6e7aeedb03
commit
fd2c4a1a29
|
@ -23,6 +23,7 @@
|
|||
<Path>ProjectSettings</Path>
|
||||
</explicitIncludes>
|
||||
<explicitExcludes>
|
||||
<Path>.git</Path>
|
||||
<Path>.idea</Path>
|
||||
<Path>Library</Path>
|
||||
<Path>Logs</Path>
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="VcsDirectoryMappings">
|
||||
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||
</component>
|
||||
</project>
|
|
@ -24,12 +24,43 @@ Transform:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 549529339}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0.48, z: 0}
|
||||
m_LocalPosition: {x: 0, y: 0.232, z: 0}
|
||||
m_LocalScale: {x: 5, y: 2, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 8805537700787760100}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &7017491928982299223
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 3858389907847018898}
|
||||
m_Layer: 0
|
||||
m_Name: Barrel
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &3858389907847018898
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 7017491928982299223}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 8805537700787760100}
|
||||
m_Father: {fileID: 8805537702490983440}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1 &8805537700787760099
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -41,7 +72,7 @@ GameObject:
|
|||
- component: {fileID: 8805537700787760100}
|
||||
- component: {fileID: 8805537700787760101}
|
||||
m_Layer: 0
|
||||
m_Name: Square
|
||||
m_Name: BarrelArt
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
|
@ -55,11 +86,11 @@ Transform:
|
|||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8805537700787760099}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0.368, y: 0.465, z: 0}
|
||||
m_LocalScale: {x: 0.2, y: 0.5, z: 1}
|
||||
m_LocalPosition: {x: 0, y: 0.24, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 549529340}
|
||||
m_Father: {fileID: 8805537702490983440}
|
||||
m_Father: {fileID: 3858389907847018898}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!212 &8805537700787760101
|
||||
|
@ -101,8 +132,8 @@ SpriteRenderer:
|
|||
m_LightmapParameters: {fileID: 0}
|
||||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
m_Sprite: {fileID: 7482667652216324306, guid: db750325989564987a34393247d883b4, type: 3}
|
||||
m_SortingOrder: 1
|
||||
m_Sprite: {fileID: -7738183107879934526, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
|
@ -142,7 +173,7 @@ Transform:
|
|||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 8805537700787760100}
|
||||
- {fileID: 3858389907847018898}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
|
@ -186,7 +217,7 @@ SpriteRenderer:
|
|||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
m_Sprite: {fileID: -2413806693520163455, guid: 4adeaf2d2b1c7417e89f026626d8264f, type: 3}
|
||||
m_Sprite: {fileID: 4319672837034334888, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
|
@ -294,3 +325,4 @@ MonoBehaviour:
|
|||
fireRate: 5
|
||||
projectileGo: {fileID: 940344813558074916, guid: 4b32e914426c07f4fa4f44db1bbc6afa, type: 3}
|
||||
projectileSpawn: {fileID: 549529340}
|
||||
barrelTransform: {fileID: 3858389907847018898}
|
||||
|
|
|
@ -77,7 +77,7 @@ GameObject:
|
|||
m_Component:
|
||||
- component: {fileID: 8235354404481829665}
|
||||
- component: {fileID: 8994506715824561311}
|
||||
- component: {fileID: 4772223738751421649}
|
||||
- component: {fileID: 6217067694903271716}
|
||||
m_Layer: 0
|
||||
m_Name: Sprite
|
||||
m_TagString: Untagged
|
||||
|
@ -94,7 +94,7 @@ Transform:
|
|||
m_GameObject: {fileID: 8329164775744005515}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 0.3, y: 0.3, z: 1}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 7492968586097603671}
|
||||
m_RootOrder: 0
|
||||
|
@ -139,8 +139,8 @@ SpriteRenderer:
|
|||
m_SortingLayerID: 0
|
||||
m_SortingLayer: 0
|
||||
m_SortingOrder: 0
|
||||
m_Sprite: {fileID: -2413806693520163455, guid: 4adeaf2d2b1c7417e89f026626d8264f, type: 3}
|
||||
m_Color: {r: 1, g: 0.9745827, b: 0, a: 1}
|
||||
m_Sprite: {fileID: 8726327230089540446, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_FlipX: 0
|
||||
m_FlipY: 0
|
||||
m_DrawMode: 0
|
||||
|
@ -150,8 +150,8 @@ SpriteRenderer:
|
|||
m_WasSpriteAssigned: 1
|
||||
m_MaskInteraction: 0
|
||||
m_SpriteSortPoint: 0
|
||||
--- !u!58 &4772223738751421649
|
||||
CircleCollider2D:
|
||||
--- !u!61 &6217067694903271716
|
||||
BoxCollider2D:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
|
@ -164,5 +164,15 @@ CircleCollider2D:
|
|||
m_UsedByEffector: 0
|
||||
m_UsedByComposite: 0
|
||||
m_Offset: {x: 0, y: 0}
|
||||
m_SpriteTilingProperty:
|
||||
border: {x: 0, y: 0, z: 0, w: 0}
|
||||
pivot: {x: 0.5, y: 0.5}
|
||||
oldSize: {x: 0.12, y: 0.26}
|
||||
newSize: {x: 1, y: 1}
|
||||
adaptiveTilingThreshold: 0.5
|
||||
drawMode: 0
|
||||
adaptiveTiling: 0
|
||||
m_AutoTiling: 0
|
||||
serializedVersion: 2
|
||||
m_Radius: 0.5
|
||||
m_Size: {x: 0.12, y: 0.26}
|
||||
m_EdgeRadius: 0
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 12c2b6762c5222147a01537f1dd3982b
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -12,6 +12,7 @@ public class Player : MonoBehaviour
|
|||
public float fireRate;
|
||||
public GameObject projectileGo;
|
||||
public Transform projectileSpawn;
|
||||
public Transform barrelTransform;
|
||||
|
||||
private Transform _transform;
|
||||
private Vector3 _position;
|
||||
|
@ -61,18 +62,20 @@ public class Player : MonoBehaviour
|
|||
angle *= -1;
|
||||
}
|
||||
|
||||
_transform.eulerAngles = Vector3.forward * angle;
|
||||
//_transform.eulerAngles = Vector3.forward * angle;
|
||||
barrelTransform.eulerAngles = Vector3.forward * angle;
|
||||
}
|
||||
|
||||
private void JoystickAim()
|
||||
{
|
||||
|
||||
// TOOD:
|
||||
}
|
||||
|
||||
private void Update()
|
||||
{
|
||||
var direction = movement.ReadValue<Vector2>();
|
||||
direction.Normalize();
|
||||
_transform.up = direction;
|
||||
direction *= speed * Time.deltaTime;
|
||||
|
||||
_position.x = direction.x;
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 9712e5601d6280a4c948648c156809c0
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Binary file not shown.
After Width: | Height: | Size: 72 KiB |
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,88 @@
|
|||
<TextureAtlas imagePath="sheet.png">
|
||||
<SubTexture name="barrelBeige.png" x="842" y="108" width="16" height="50"/>
|
||||
<SubTexture name="barrelBeige_outline.png" x="840" y="368" width="24" height="58"/>
|
||||
<SubTexture name="barrelBlack.png" x="840" y="426" width="16" height="50"/>
|
||||
<SubTexture name="barrelBlack_outline.png" x="818" y="168" width="24" height="58"/>
|
||||
<SubTexture name="barrelBlue.png" x="850" y="58" width="16" height="50"/>
|
||||
<SubTexture name="barrelBlue_outline.png" x="827" y="226" width="24" height="58"/>
|
||||
<SubTexture name="barrelGreen.png" x="834" y="58" width="16" height="50"/>
|
||||
<SubTexture name="barrelGreen_outline.png" x="818" y="110" width="24" height="58"/>
|
||||
<SubTexture name="barrelGreen_side.png" x="746" y="48" width="44" height="62"/>
|
||||
<SubTexture name="barrelGreen_side_damaged.png" x="790" y="48" width="44" height="62"/>
|
||||
<SubTexture name="barrelGreen_up.png" x="746" y="0" width="48" height="48"/>
|
||||
<SubTexture name="barrelGrey_sde_rust.png" x="783" y="244" width="44" height="62"/>
|
||||
<SubTexture name="barrelGrey_side.png" x="796" y="410" width="44" height="62"/>
|
||||
<SubTexture name="barrelGrey_up.png" x="735" y="252" width="48" height="48"/>
|
||||
<SubTexture name="barrelRed.png" x="842" y="158" width="16" height="50"/>
|
||||
<SubTexture name="barrelRed_outline.png" x="834" y="0" width="24" height="58"/>
|
||||
<SubTexture name="barrelRed_side.png" x="805" y="306" width="44" height="62"/>
|
||||
<SubTexture name="barrelRed_up.png" x="730" y="454" width="48" height="48"/>
|
||||
<SubTexture name="bulletBeige.png" x="48" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletBeigeSilver.png" x="188" y="345" width="12" height="26"/>
|
||||
<SubTexture name="bulletBeigeSilver_outline.png" x="671" y="140" width="20" height="34"/>
|
||||
<SubTexture name="bulletBeige_outline.png" x="128" y="345" width="20" height="34"/>
|
||||
<SubTexture name="bulletBlue.png" x="0" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletBlueSilver.png" x="12" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletBlueSilver_outline.png" x="148" y="345" width="20" height="34"/>
|
||||
<SubTexture name="bulletBlue_outline.png" x="755" y="300" width="20" height="34"/>
|
||||
<SubTexture name="bulletGreen.png" x="24" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletGreenSilver.png" x="36" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletGreenSilver_outline.png" x="691" y="140" width="20" height="34"/>
|
||||
<SubTexture name="bulletGreen_outline.png" x="168" y="345" width="20" height="34"/>
|
||||
<SubTexture name="bulletRed.png" x="120" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletRedSilver.png" x="60" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletRedSilver_outline.png" x="711" y="140" width="20" height="34"/>
|
||||
<SubTexture name="bulletRed_outline.png" x="735" y="300" width="20" height="34"/>
|
||||
<SubTexture name="bulletSilver.png" x="72" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletSilverSilver.png" x="84" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletSilverSilver_outline.png" x="778" y="472" width="20" height="34"/>
|
||||
<SubTexture name="bulletSilver_outline.png" x="775" y="306" width="20" height="34"/>
|
||||
<SubTexture name="bulletYellow.png" x="96" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletYellowSilver.png" x="108" y="481" width="12" height="26"/>
|
||||
<SubTexture name="bulletYellowSilver_outline.png" x="794" y="0" width="20" height="34"/>
|
||||
<SubTexture name="bulletYellow_outline.png" x="814" y="0" width="20" height="34"/>
|
||||
<SubTexture name="dirt.png" x="0" y="0" width="128" height="128"/>
|
||||
<SubTexture name="grass.png" x="0" y="128" width="128" height="128"/>
|
||||
<SubTexture name="oil.png" x="200" y="408" width="96" height="96"/>
|
||||
<SubTexture name="sand.png" x="0" y="256" width="128" height="128"/>
|
||||
<SubTexture name="sandbagBeige.png" x="128" y="301" width="66" height="44"/>
|
||||
<SubTexture name="sandbagBrown.png" x="730" y="410" width="66" height="44"/>
|
||||
<SubTexture name="smokeGrey0.png" x="416" y="188" width="87" height="87"/>
|
||||
<SubTexture name="smokeGrey1.png" x="296" y="408" width="92" height="89"/>
|
||||
<SubTexture name="smokeGrey2.png" x="478" y="384" width="90" height="99"/>
|
||||
<SubTexture name="smokeGrey3.png" x="651" y="353" width="79" height="79"/>
|
||||
<SubTexture name="smokeGrey4.png" x="128" y="97" width="100" height="97"/>
|
||||
<SubTexture name="smokeGrey5.png" x="128" y="194" width="98" height="107"/>
|
||||
<SubTexture name="smokeOrange0.png" x="486" y="275" width="87" height="87"/>
|
||||
<SubTexture name="smokeOrange1.png" x="324" y="196" width="92" height="89"/>
|
||||
<SubTexture name="smokeOrange2.png" x="388" y="408" width="90" height="99"/>
|
||||
<SubTexture name="smokeOrange3.png" x="656" y="261" width="79" height="79"/>
|
||||
<SubTexture name="smokeOrange4.png" x="0" y="384" width="100" height="97"/>
|
||||
<SubTexture name="smokeOrange5.png" x="228" y="0" width="98" height="107"/>
|
||||
<SubTexture name="smokeWhite0.png" x="324" y="107" width="92" height="89"/>
|
||||
<SubTexture name="smokeWhite1.png" x="396" y="285" width="90" height="99"/>
|
||||
<SubTexture name="smokeWhite2.png" x="590" y="182" width="79" height="79"/>
|
||||
<SubTexture name="smokeWhite3.png" x="128" y="0" width="100" height="97"/>
|
||||
<SubTexture name="smokeWhite4.png" x="226" y="194" width="98" height="107"/>
|
||||
<SubTexture name="smokeWhite5.png" x="418" y="0" width="87" height="87"/>
|
||||
<SubTexture name="smokeYellow0.png" x="228" y="107" width="87" height="87"/>
|
||||
<SubTexture name="smokeYellow1.png" x="326" y="0" width="92" height="89"/>
|
||||
<SubTexture name="smokeYellow2.png" x="416" y="89" width="90" height="99"/>
|
||||
<SubTexture name="smokeYellow3.png" x="651" y="432" width="79" height="79"/>
|
||||
<SubTexture name="smokeYellow4.png" x="100" y="384" width="100" height="97"/>
|
||||
<SubTexture name="smokeYellow5.png" x="298" y="301" width="98" height="107"/>
|
||||
<SubTexture name="tankBeige.png" x="730" y="340" width="75" height="70"/>
|
||||
<SubTexture name="tankBeige_outline.png" x="505" y="0" width="83" height="78"/>
|
||||
<SubTexture name="tankBlack.png" x="671" y="0" width="75" height="70"/>
|
||||
<SubTexture name="tankBlack_outline.png" x="568" y="362" width="83" height="78"/>
|
||||
<SubTexture name="tankBlue.png" x="671" y="70" width="75" height="70"/>
|
||||
<SubTexture name="tankBlue_outline.png" x="506" y="78" width="83" height="78"/>
|
||||
<SubTexture name="tankGreen.png" x="669" y="182" width="75" height="70"/>
|
||||
<SubTexture name="tankGreen_outline.png" x="573" y="275" width="83" height="78"/>
|
||||
<SubTexture name="tankRed.png" x="568" y="440" width="75" height="70"/>
|
||||
<SubTexture name="tankRed_outline.png" x="588" y="0" width="83" height="78"/>
|
||||
<SubTexture name="tracksLarge.png" x="589" y="78" width="82" height="104"/>
|
||||
<SubTexture name="tracksSmall.png" x="744" y="140" width="74" height="104"/>
|
||||
<SubTexture name="treeLarge.png" x="200" y="301" width="98" height="107"/>
|
||||
<SubTexture name="treeSmall.png" x="503" y="188" width="87" height="87"/>
|
||||
</TextureAtlas>
|
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 77c827883ce0f6946a1db40289521471
|
||||
TextScriptImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 80a26f0e21530d64e9826c6553151b89
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,9 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 23aa647f2fb21bf46b850587506ba4a2
|
||||
folderAsset: yes
|
||||
timeCreated: 1430572177
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,281 @@
|
|||
using System;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Xml;
|
||||
using UnityEditor;
|
||||
using UnityEngine;
|
||||
|
||||
public class TextureAtlasSlicer : EditorWindow {
|
||||
[MenuItem("CONTEXT/TextureImporter/Slice Sprite Using XML")]
|
||||
public static void SliceUsingXML(MenuCommand command) {
|
||||
var textureImporter = command.context as TextureImporter;
|
||||
|
||||
var window = CreateInstance<TextureAtlasSlicer>();
|
||||
|
||||
window.importer = textureImporter;
|
||||
|
||||
window.ShowUtility();
|
||||
}
|
||||
|
||||
[MenuItem("Assets/Slice Sprite Using XML")]
|
||||
public static void TextureAtlasSlicerWindow() {
|
||||
var window = CreateInstance<TextureAtlasSlicer>();
|
||||
|
||||
window.Show();
|
||||
}
|
||||
|
||||
[MenuItem("CONTEXT/TextureImporter/Slice Sprite Using XML", true)]
|
||||
public static bool ValidateSliceUsingXML(MenuCommand command) {
|
||||
var textureImporter = command.context as TextureImporter;
|
||||
|
||||
//valid only if the texture type is 'sprite' or 'advanced'.
|
||||
return textureImporter && textureImporter.textureType == TextureImporterType.Sprite ||
|
||||
textureImporter.textureType == TextureImporterType.Default;
|
||||
}
|
||||
|
||||
public TextureImporter importer;
|
||||
|
||||
public TextureAtlasSlicer() {
|
||||
titleContent = new GUIContent("XML Slicer");
|
||||
}
|
||||
|
||||
|
||||
[SerializeField]
|
||||
private TextAsset xmlAsset;
|
||||
|
||||
public SpriteAlignment spriteAlignment = SpriteAlignment.Center;
|
||||
|
||||
public Vector2 customOffset = new Vector2(0.5f, 0.5f);
|
||||
|
||||
public void OnSelectionChange() {
|
||||
UseSelectedTexture();
|
||||
}
|
||||
|
||||
private Texture2D selectedTexture;
|
||||
|
||||
private void UseSelectedTexture() {
|
||||
if (Selection.objects.Length > 1) {
|
||||
selectedTexture = null;
|
||||
} else {
|
||||
selectedTexture = Selection.activeObject as Texture2D;
|
||||
}
|
||||
|
||||
if (selectedTexture != null) {
|
||||
var assetPath = AssetDatabase.GetAssetPath(selectedTexture);
|
||||
|
||||
importer = AssetImporter.GetAtPath(assetPath) as TextureImporter;
|
||||
|
||||
if (importer) {
|
||||
var extension = Path.GetExtension(assetPath);
|
||||
var pathWithoutExtension = assetPath.Remove(assetPath.Length - extension.Length, extension.Length);
|
||||
|
||||
var xmlPath = pathWithoutExtension + ".xml";
|
||||
|
||||
var textAsset = AssetDatabase.LoadAssetAtPath(xmlPath, typeof (TextAsset));
|
||||
|
||||
if (textAsset != null) {
|
||||
xmlAsset = textAsset as TextAsset;
|
||||
} else {
|
||||
xmlAsset = null;
|
||||
subTextures = null;
|
||||
}
|
||||
|
||||
ParseXML();
|
||||
} else {
|
||||
xmlAsset = null;
|
||||
subTextures = null;
|
||||
}
|
||||
} else {
|
||||
importer = null;
|
||||
xmlAsset = null;
|
||||
subTextures = null;
|
||||
}
|
||||
|
||||
Repaint();
|
||||
}
|
||||
|
||||
private SubTexture[] subTextures;
|
||||
private int wantedWidth, wantedHeight;
|
||||
|
||||
private void ParseXML() {
|
||||
try {
|
||||
var document = new XmlDocument();
|
||||
document.LoadXml(xmlAsset.text);
|
||||
|
||||
var root = document.DocumentElement;
|
||||
if (root == null || root.Name != "TextureAtlas") {
|
||||
return;
|
||||
}
|
||||
|
||||
subTextures = root.ChildNodes
|
||||
.Cast<XmlNode>()
|
||||
.Where(childNode => childNode.Name == "SubTexture")
|
||||
.Select(childNode => new SubTexture {
|
||||
width = Convert.ToInt32(childNode.Attributes["width"].Value),
|
||||
height = Convert.ToInt32(childNode.Attributes["height"].Value),
|
||||
x = Convert.ToInt32(childNode.Attributes["x"].Value),
|
||||
y = Convert.ToInt32(childNode.Attributes["y"].Value),
|
||||
name = childNode.Attributes["name"].Value
|
||||
}).ToArray();
|
||||
|
||||
wantedWidth = 0;
|
||||
wantedHeight = 0;
|
||||
|
||||
foreach (var subTexture in subTextures) {
|
||||
var right = subTexture.x + subTexture.width;
|
||||
var bottom = subTexture.y + subTexture.height;
|
||||
|
||||
wantedWidth = Mathf.Max(wantedWidth, right);
|
||||
wantedHeight = Mathf.Max(wantedHeight, bottom);
|
||||
}
|
||||
} catch (Exception) {
|
||||
subTextures = null;
|
||||
}
|
||||
}
|
||||
|
||||
public void OnEnable() {
|
||||
UseSelectedTexture();
|
||||
}
|
||||
|
||||
public void OnGUI() {
|
||||
if (importer == null) {
|
||||
EditorGUILayout.LabelField("Please select a texture to slice.");
|
||||
return;
|
||||
}
|
||||
EditorGUI.BeginDisabledGroup(focusedWindow != this);
|
||||
{
|
||||
EditorGUI.BeginDisabledGroup(true);
|
||||
EditorGUILayout.ObjectField("Texture", Selection.activeObject, typeof (Texture), false);
|
||||
EditorGUI.EndDisabledGroup();
|
||||
|
||||
if (importer.textureType != TextureImporterType.Sprite &&
|
||||
importer.textureType != TextureImporterType.Default) {
|
||||
EditorGUILayout.LabelField("The Texture Type needs to be Sprite or Advanced!");
|
||||
}
|
||||
|
||||
EditorGUI.BeginDisabledGroup((importer.textureType != TextureImporterType.Sprite &&
|
||||
importer.textureType != TextureImporterType.Default));
|
||||
{
|
||||
EditorGUI.BeginChangeCheck();
|
||||
xmlAsset = EditorGUILayout.ObjectField("XML Source", xmlAsset, typeof (TextAsset), false) as TextAsset;
|
||||
if (EditorGUI.EndChangeCheck()) {
|
||||
ParseXML();
|
||||
}
|
||||
|
||||
spriteAlignment = (SpriteAlignment) EditorGUILayout.EnumPopup("Pivot", spriteAlignment);
|
||||
|
||||
EditorGUI.BeginDisabledGroup(spriteAlignment != SpriteAlignment.Custom);
|
||||
EditorGUILayout.Vector2Field("Custom Offset", customOffset);
|
||||
EditorGUI.EndDisabledGroup();
|
||||
|
||||
var needsToResizeTexture = wantedWidth > selectedTexture.width || wantedHeight > selectedTexture.height;
|
||||
|
||||
if (xmlAsset != null && needsToResizeTexture) {
|
||||
EditorGUILayout.LabelField(
|
||||
string.Format("Texture size too small."
|
||||
+ " It needs to be at least {0} by {1} pixels!",
|
||||
wantedWidth,
|
||||
wantedHeight));
|
||||
EditorGUILayout.LabelField("Try changing the Max Size property in the importer.");
|
||||
}
|
||||
|
||||
if (subTextures == null || subTextures.Length == 0) {
|
||||
EditorGUILayout.LabelField("Could not find any SubTextures in XML.");
|
||||
}
|
||||
|
||||
EditorGUI.BeginDisabledGroup(xmlAsset == null || needsToResizeTexture || subTextures == null ||
|
||||
subTextures.Length == 0);
|
||||
if (GUILayout.Button("Slice")) {
|
||||
PerformSlice();
|
||||
}
|
||||
EditorGUI.EndDisabledGroup();
|
||||
}
|
||||
EditorGUI.EndDisabledGroup();
|
||||
}
|
||||
EditorGUI.EndDisabledGroup();
|
||||
}
|
||||
|
||||
private struct SubTexture {
|
||||
public int width;
|
||||
public int height;
|
||||
public int x;
|
||||
public int y;
|
||||
public string name;
|
||||
}
|
||||
|
||||
private void PerformSlice() {
|
||||
if (importer == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
var textureHeight = selectedTexture.height;
|
||||
|
||||
var needsUpdate = false;
|
||||
|
||||
if (importer.spriteImportMode != SpriteImportMode.Multiple) {
|
||||
needsUpdate = true;
|
||||
importer.spriteImportMode = SpriteImportMode.Multiple;
|
||||
}
|
||||
|
||||
var wantedSpriteSheet = (from subTexture in subTextures
|
||||
let actualY = textureHeight - (subTexture.y + subTexture.height)
|
||||
select new SpriteMetaData {
|
||||
alignment = (int) spriteAlignment,
|
||||
border = new Vector4(),
|
||||
name = subTexture.name,
|
||||
pivot = GetPivotValue(spriteAlignment, customOffset),
|
||||
rect = new Rect(subTexture.x, actualY, subTexture.width, subTexture.height)
|
||||
}).ToArray();
|
||||
if (!needsUpdate && !importer.spritesheet.SequenceEqual(wantedSpriteSheet)) {
|
||||
needsUpdate = true;
|
||||
importer.spritesheet = wantedSpriteSheet;
|
||||
}
|
||||
|
||||
if (needsUpdate) {
|
||||
EditorUtility.SetDirty(importer);
|
||||
|
||||
try {
|
||||
AssetDatabase.StartAssetEditing();
|
||||
AssetDatabase.ImportAsset(importer.assetPath);
|
||||
|
||||
EditorUtility.DisplayDialog("Success!", "The sprite was sliced successfully.", "OK");
|
||||
} catch (Exception exception) {
|
||||
Debug.LogException(exception);
|
||||
EditorUtility.DisplayDialog("Error", "There was an exception while trying to reimport the image." +
|
||||
"\nPlease check the console log for details.", "OK");
|
||||
} finally {
|
||||
AssetDatabase.StopAssetEditing();
|
||||
}
|
||||
} else {
|
||||
EditorUtility.DisplayDialog("Nope!", "The sprite is already sliced according to this XML file.", "OK");
|
||||
}
|
||||
}
|
||||
|
||||
//SpriteEditorUtility
|
||||
public static Vector2 GetPivotValue(SpriteAlignment alignment, Vector2 customOffset) {
|
||||
switch (alignment) {
|
||||
case SpriteAlignment.Center:
|
||||
return new Vector2(0.5f, 0.5f);
|
||||
case SpriteAlignment.TopLeft:
|
||||
return new Vector2(0.0f, 1f);
|
||||
case SpriteAlignment.TopCenter:
|
||||
return new Vector2(0.5f, 1f);
|
||||
case SpriteAlignment.TopRight:
|
||||
return new Vector2(1f, 1f);
|
||||
case SpriteAlignment.LeftCenter:
|
||||
return new Vector2(0.0f, 0.5f);
|
||||
case SpriteAlignment.RightCenter:
|
||||
return new Vector2(1f, 0.5f);
|
||||
case SpriteAlignment.BottomLeft:
|
||||
return new Vector2(0.0f, 0.0f);
|
||||
case SpriteAlignment.BottomCenter:
|
||||
return new Vector2(0.5f, 0.0f);
|
||||
case SpriteAlignment.BottomRight:
|
||||
return new Vector2(1f, 0.0f);
|
||||
case SpriteAlignment.Custom:
|
||||
return customOffset;
|
||||
default:
|
||||
return Vector2.zero;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,12 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 2067bd0762faf2c48910fee768c92901
|
||||
timeCreated: 1430572201
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,17 @@
|
|||
# Unity3D-TextureAtlasSlicer
|
||||
Simple and fast tool to import XML spritesheets (TextureAtlas) into Unity3D!
|
||||
|
||||
![Preview Image](https://i.imgur.com/LhmcMjX.png)
|
||||
|
||||
Works very well to import [Kenney's sprite assets](http://opengameart.org/users/kenney)!
|
||||
|
||||
## Usage
|
||||
- Copy this folder to your project's assets directory, or just use the latest .unitypackage file from the [Github project's releases](https://github.com/toxicFork/Unity3D-TextureAtlasSlicer/releases), or the [Unity3D asset store](https://www.assetstore.unity3d.com/en/#!/content/36103)!
|
||||
- You can now use the Assets/Slice Sprite Using XML button!
|
||||
- This will open a window.
|
||||
- Select any sprite asset in your Project window
|
||||
- If it has a XML file with the same name next to it, that XML file will automatically be selected
|
||||
- Otherwise, drag-drop the XML file reference onto the XML Source field in the Texture Atlas Slicer window
|
||||
- Configure the pivot settings
|
||||
- Hit Slice!
|
||||
- Enjoy! :D
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 463e84607d141d645b70834aa062a0d1
|
||||
timeCreated: 1430859603
|
||||
licenseType: Store
|
||||
DefaultImporter:
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 81a7d8c0d5f927e4d93b0587653e0bfc
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,269 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!1 &3231926778117611191
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 2993903815236689195}
|
||||
- component: {fileID: 3069919563668379665}
|
||||
- component: {fileID: 3702712802494335279}
|
||||
m_Layer: 0
|
||||
m_Name: Layer1
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &2993903815236689195
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3231926778117611191}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 5462071905097943538}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!1839735485 &3069919563668379665
|
||||
Tilemap:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3231926778117611191}
|
||||
m_Enabled: 1
|
||||
m_Tiles:
|
||||
- first: {x: -4, y: -1, z: 0}
|
||||
second:
|
||||
serializedVersion: 2
|
||||
m_TileIndex: 2
|
||||
m_TileSpriteIndex: 2
|
||||
m_TileMatrixIndex: 0
|
||||
m_TileColorIndex: 0
|
||||
m_TileObjectToInstantiateIndex: 65535
|
||||
dummyAlignment: 0
|
||||
m_AllTileFlags: 1073741825
|
||||
- first: {x: -1, y: -1, z: 0}
|
||||
second:
|
||||
serializedVersion: 2
|
||||
m_TileIndex: 4
|
||||
m_TileSpriteIndex: 4
|
||||
m_TileMatrixIndex: 0
|
||||
m_TileColorIndex: 0
|
||||
m_TileObjectToInstantiateIndex: 65535
|
||||
dummyAlignment: 0
|
||||
m_AllTileFlags: 1073741825
|
||||
- first: {x: -4, y: 0, z: 0}
|
||||
second:
|
||||
serializedVersion: 2
|
||||
m_TileIndex: 0
|
||||
m_TileSpriteIndex: 0
|
||||
m_TileMatrixIndex: 0
|
||||
m_TileColorIndex: 0
|
||||
m_TileObjectToInstantiateIndex: 65535
|
||||
dummyAlignment: 0
|
||||
m_AllTileFlags: 1073741825
|
||||
- first: {x: -3, y: 0, z: 0}
|
||||
second:
|
||||
serializedVersion: 2
|
||||
m_TileIndex: 1
|
||||
m_TileSpriteIndex: 1
|
||||
m_TileMatrixIndex: 0
|
||||
m_TileColorIndex: 0
|
||||
m_TileObjectToInstantiateIndex: 65535
|
||||
dummyAlignment: 0
|
||||
m_AllTileFlags: 1073741825
|
||||
- first: {x: -1, y: 0, z: 0}
|
||||
second:
|
||||
serializedVersion: 2
|
||||
m_TileIndex: 3
|
||||
m_TileSpriteIndex: 3
|
||||
m_TileMatrixIndex: 0
|
||||
m_TileColorIndex: 0
|
||||
m_TileObjectToInstantiateIndex: 65535
|
||||
dummyAlignment: 0
|
||||
m_AllTileFlags: 1073741825
|
||||
m_AnimatedTiles: {}
|
||||
m_TileAssetArray:
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 11400000, guid: f538d628f059243408be8937e31d4d0f, type: 2}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 11400000, guid: 72ba34ff2187dee489531ff49db25160, type: 2}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 11400000, guid: 0a3471f2f8b0b324cb7c73da3db711a3, type: 2}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 11400000, guid: c4e26166a282d5746bcdb4c326d32d36, type: 2}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 11400000, guid: 8ab5634c7804af644be91f1e374a7551, type: 2}
|
||||
m_TileSpriteArray:
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: -482986622496041442, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: -1010530962649890918, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 5315189978236590363, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: -8262074229558958461, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
- m_RefCount: 1
|
||||
m_Data: {fileID: 8707436237485916330, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_TileMatrixArray:
|
||||
- m_RefCount: 5
|
||||
m_Data:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
m_TileColorArray:
|
||||
- m_RefCount: 5
|
||||
m_Data: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_TileObjectToInstantiateArray: []
|
||||
m_AnimationFrameRate: 1
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Origin: {x: -4, y: -1, z: 0}
|
||||
m_Size: {x: 4, y: 2, z: 1}
|
||||
m_TileAnchor: {x: 0.5, y: 0.5, z: 0}
|
||||
m_TileOrientation: 0
|
||||
m_TileOrientationMatrix:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
--- !u!483693784 &3702712802494335279
|
||||
TilemapRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3231926778117611191}
|
||||
m_Enabled: 1
|
||||
m_CastShadows: 0
|
||||
m_ReceiveShadows: 0
|
||||
m_DynamicOccludee: 0
|
||||
m_MotionVectors: 1
|
||||
m_LightProbeUsage: 0
|
||||
m_ReflectionProbeUsage: 0
|
||||
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: 0
|
||||
m_ChunkSize: {x: 32, y: 32, z: 32}
|
||||
m_ChunkCullingBounds: {x: 0.13999999, y: 0.13999999, z: 0}
|
||||
m_MaxChunkCount: 16
|
||||
m_MaxFrameAge: 16
|
||||
m_SortOrder: 0
|
||||
m_Mode: 0
|
||||
m_DetectChunkCullingBounds: 0
|
||||
m_MaskInteraction: 0
|
||||
--- !u!1 &8137610160812789494
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5462071905097943538}
|
||||
- component: {fileID: 6746717149875547772}
|
||||
m_Layer: 31
|
||||
m_Name: Level
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!4 &5462071905097943538
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8137610160812789494}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 2993903815236689195}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
--- !u!156049354 &6746717149875547772
|
||||
Grid:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8137610160812789494}
|
||||
m_Enabled: 1
|
||||
m_CellSize: {x: 1.28, y: 1.28, z: 0}
|
||||
m_CellGap: {x: 0, y: 0, z: 0}
|
||||
m_CellLayout: 0
|
||||
m_CellSwizzle: 0
|
||||
--- !u!114 &3260828179623479687
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 12395, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Name: Palette Settings
|
||||
m_EditorClassIdentifier:
|
||||
cellSizing: 0
|
||||
m_TransparencySortMode: 0
|
||||
m_TransparencySortAxis: {x: 0, y: 0, z: 1}
|
|
@ -0,0 +1,7 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 7f29f9bd39e68ee43a3fd06fc3ff9cb2
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,36 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 13312, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Name: dirt.png
|
||||
m_EditorClassIdentifier:
|
||||
m_Sprite: {fileID: 5315189978236590363, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Transform:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
m_InstancedGameObject: {fileID: 0}
|
||||
m_Flags: 1
|
||||
m_ColliderType: 1
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 0a3471f2f8b0b324cb7c73da3db711a3
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,36 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 13312, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Name: grass.png
|
||||
m_EditorClassIdentifier:
|
||||
m_Sprite: {fileID: -1010530962649890918, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Transform:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
m_InstancedGameObject: {fileID: 0}
|
||||
m_Flags: 1
|
||||
m_ColliderType: 1
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 72ba34ff2187dee489531ff49db25160
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,36 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 13312, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Name: sand.png
|
||||
m_EditorClassIdentifier:
|
||||
m_Sprite: {fileID: -482986622496041442, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Transform:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
m_InstancedGameObject: {fileID: 0}
|
||||
m_Flags: 1
|
||||
m_ColliderType: 1
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: f538d628f059243408be8937e31d4d0f
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,36 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 13312, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Name: treeLarge.png
|
||||
m_EditorClassIdentifier:
|
||||
m_Sprite: {fileID: -8262074229558958461, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Transform:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
m_InstancedGameObject: {fileID: 0}
|
||||
m_Flags: 1
|
||||
m_ColliderType: 1
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: c4e26166a282d5746bcdb4c326d32d36
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -0,0 +1,36 @@
|
|||
%YAML 1.1
|
||||
%TAG !u! tag:unity3d.com,2011:
|
||||
--- !u!114 &11400000
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 0}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 13312, guid: 0000000000000000e000000000000000, type: 0}
|
||||
m_Name: treeSmall.png
|
||||
m_EditorClassIdentifier:
|
||||
m_Sprite: {fileID: 8707436237485916330, guid: e3947200ccf82a24a9a0027459618d55, type: 3}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_Transform:
|
||||
e00: 1
|
||||
e01: 0
|
||||
e02: 0
|
||||
e03: 0
|
||||
e10: 0
|
||||
e11: 1
|
||||
e12: 0
|
||||
e13: 0
|
||||
e20: 0
|
||||
e21: 0
|
||||
e22: 1
|
||||
e23: 0
|
||||
e30: 0
|
||||
e31: 0
|
||||
e32: 0
|
||||
e33: 1
|
||||
m_InstancedGameObject: {fileID: 0}
|
||||
m_Flags: 1
|
||||
m_ColliderType: 1
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 8ab5634c7804af644be91f1e374a7551
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 11400000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -1,2 +1,2 @@
|
|||
m_EditorVersion: 2020.2.2f1
|
||||
m_EditorVersionWithRevision: 2020.2.2f1 (068178b99f32)
|
||||
m_EditorVersion: 2020.2.4f1
|
||||
m_EditorVersionWithRevision: 2020.2.4f1 (becced5a802b)
|
||||
|
|
|
@ -165,7 +165,7 @@ QualitySettings:
|
|||
skinWeights: 4
|
||||
textureQuality: 0
|
||||
anisotropicTextures: 2
|
||||
antiAliasing: 2
|
||||
antiAliasing: 0
|
||||
softParticles: 1
|
||||
softVegetation: 1
|
||||
realtimeReflectionProbes: 1
|
||||
|
@ -201,7 +201,7 @@ QualitySettings:
|
|||
skinWeights: 255
|
||||
textureQuality: 0
|
||||
anisotropicTextures: 2
|
||||
antiAliasing: 2
|
||||
antiAliasing: 0
|
||||
softParticles: 1
|
||||
softVegetation: 1
|
||||
realtimeReflectionProbes: 1
|
||||
|
|
|
@ -0,0 +1,167 @@
|
|||
{
|
||||
"templatePinStates": [],
|
||||
"dependencyTypeInfos": [
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.AnimationClip",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEditor.Animations.AnimatorController",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.AnimatorOverrideController",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEditor.Audio.AudioMixerController",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.ComputeShader",
|
||||
"ignore": true,
|
||||
"defaultInstantiationMode": 1,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Cubemap",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.GameObject",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEditor.LightingDataAsset",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": false
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.LightingSettings",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Material",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEditor.MonoScript",
|
||||
"ignore": true,
|
||||
"defaultInstantiationMode": 1,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.PhysicMaterial",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.PhysicsMaterial2D",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Rendering.PostProcessing.PostProcessProfile",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Rendering.PostProcessing.PostProcessResources",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Rendering.VolumeProfile",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEditor.SceneAsset",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": false
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Shader",
|
||||
"ignore": true,
|
||||
"defaultInstantiationMode": 1,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.ShaderVariantCollection",
|
||||
"ignore": true,
|
||||
"defaultInstantiationMode": 1,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Texture",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Texture2D",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
},
|
||||
{
|
||||
"userAdded": false,
|
||||
"type": "UnityEngine.Timeline.TimelineAsset",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 0,
|
||||
"supportsModification": true
|
||||
}
|
||||
],
|
||||
"defaultDependencyTypeInfo": {
|
||||
"userAdded": false,
|
||||
"type": "<default_scene_template_dependencies>",
|
||||
"ignore": false,
|
||||
"defaultInstantiationMode": 1,
|
||||
"supportsModification": true
|
||||
},
|
||||
"newSceneOverride": 0
|
||||
}
|
Loading…
Reference in New Issue