Skip to content

Commit

Permalink
add ermshark egg
Browse files Browse the repository at this point in the history
  • Loading branch information
Govorunb committed May 17, 2024
1 parent e02913e commit 58d049a
Show file tree
Hide file tree
Showing 36 changed files with 1,249 additions and 135 deletions.
20 changes: 8 additions & 12 deletions SCHIZO/Items/Components/ModdedCreatureEgg.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,15 @@ namespace SCHIZO.Items.Components;

partial class ModdedCreatureEgg
{
private CreatureEgg Egg => creatureEgg as CreatureEgg;
private void Awake()
{
CreatureEgg egg = gameObject.AddComponent<CreatureEgg>();
egg.creaturePrefab = new CustomGameObjectReference(creature.GetClassID());
egg.creatureType = creature.GetTechType();
egg.daysBeforeHatching = daysBeforeHatching;
#if BELOWZERO
egg.animators = [animator];
egg.animateOutside = true; // todo
#else
egg.animator = animator;
#endif
egg.liveMixin = (LiveMixin)liveMixin;
// TODO: hatching progress deserialization
if (!Egg)
{
LOGGER.LogWarning($"{nameof(creatureEgg)} was not assigned to {this}, creating new - deserialization (e.g. loading hatching progress from save) will fail!");
creatureEgg = gameObject.AddComponent<CreatureEgg>();
}
Egg.creaturePrefab = new CustomGameObjectReference(creature.GetClassID());
Egg.creatureType = creature.GetTechType();
}
}
2 changes: 1 addition & 1 deletion SCHIZO/Resources/AssetBundles/Assets.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ namespace SCHIZO.Resources;

public static class Assets
{
private const int _rnd = 1060035311;
private const int _rnd = -980082882;

private static readonly UnityEngine.AssetBundle _a = ResourceManager.GetAssetBundle("assets");

Expand Down
Binary file modified SCHIZO/Resources/AssetBundles/assets
Binary file not shown.
2 changes: 1 addition & 1 deletion Unity/Assets/Mod/Anneel/Anneel data.asset
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ MonoBehaviour:
id: 0
classId: anneel
displayName: Anneel
tooltip: 'Very stretchy. Born in containment.
tooltip: '[PH] Very stretchy. Born in containment.
<size=75%>(Model by bred)</size>'
icon: {fileID: 21300000, guid: 1f6b8c274fb392d47a69d0e749afcd3c, type: 3}
Expand Down
5 changes: 3 additions & 2 deletions Unity/Assets/Mod/Anneel/Anneel egg.asset
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@ MonoBehaviour:
id: 0
classId: anneelEgg
displayName: Anneel Egg
tooltip: 'Erm... Don''t think about it too much.
tooltip: '[PH] Erm... Don''t think about it too much.
<size=75%>(Model by Toasted3)</size>'
<size=75%>(Model by
Toasted3)</size>'
icon: {fileID: 21300000, guid: f147f897f2453f3429d7eee07fc7af6c, type: 3}
itemSize: {x: 1, y: 1}
isCraftable: 0
Expand Down
110 changes: 75 additions & 35 deletions Unity/Assets/Mod/Anneel/Anneel egg.prefab
Original file line number Diff line number Diff line change
@@ -1,5 +1,36 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &5473300125322192417
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2537258640723971557}
m_Layer: 0
m_Name: Model
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2537258640723971557
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5473300125322192417}
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: 2203447209914860770}
m_Father: {fileID: 1563381355764448331}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!54 &4890550523810032676
Rigidbody:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -47,6 +78,48 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: fca8adfc2fbf477ab03d827042078a67, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &-5055116498464323930
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7988108974593223574}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3bd515b4ecee2e740913386f4c4008e6, type: 3}
m_Name:
m_EditorClassIdentifier:
daysBeforeHatching: 1.5
creaturePrefab:
m_AssetGUID:
m_SubObjectName:
m_SubObjectType:
m_EditorAssetChanged: 0
liveMixin: {fileID: 7862938925676357923}
animator: {fileID: 0}
animators: []
--- !u!114 &706281257449717565
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7988108974593223574}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3bd515b4ecee2e740913386f4c4008e6, type: 3}
m_Name:
m_EditorClassIdentifier:
daysBeforeHatching: 1
creaturePrefab:
m_AssetGUID:
m_SubObjectName:
m_SubObjectType:
m_EditorAssetChanged: 0
liveMixin: {fileID: 7862938925676357923}
animator: {fileID: 0}
animators: []
--- !u!114 &3206676238923503873
MonoBehaviour:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -81,13 +154,11 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 368ff21a5227eb049b4a948b0437f864, type: 3}
m_Name:
m_EditorClassIdentifier:
liveMixin: {fileID: 7862938925676357923}
creatureEgg: {fileID: 706281257449717565}
creature:
isCustom: 1
techType: 0
itemData: {fileID: 11400000, guid: 87067f32545a0f74b95731190912dcd3, type: 2}
daysBeforeHatching: 1.5
animator: {fileID: -2118284749188149188}
--- !u!114 &7862938925676357923
MonoBehaviour:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -123,37 +194,6 @@ MonoBehaviour:
randomizeRotationWhenDropped: 1
activateRigidbodyWhenDropped: 1
usePackUpIcon: 0
--- !u!1 &5473300125322192417
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2537258640723971557}
m_Layer: 0
m_Name: Model
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2537258640723971557
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 5473300125322192417}
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: 2203447209914860770}
m_Father: {fileID: 1563381355764448331}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1001 &1171686608730354531
PrefabInstance:
m_ObjectHideFlags: 0
Expand Down Expand Up @@ -229,7 +269,7 @@ PrefabInstance:
- target: {fileID: 9122564453119383797, guid: c4afaa0bdc846574aa2185e0c81013f9,
type: 3}
propertyPath: m_Name
value: '''anneel'' ''egg'''
value: Anneel egg
objectReference: {fileID: 0}
m_RemovedComponents:
- {fileID: 3307992340188546611, guid: c4afaa0bdc846574aa2185e0c81013f9, type: 3}
Expand Down
8 changes: 8 additions & 0 deletions Unity/Assets/Mod/Anneel/Icons.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

85 changes: 85 additions & 0 deletions Unity/Assets/Mod/Ermshark/Ermshark Egg.asset
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-9216567195626357826
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: 11500000, guid: d5fc571188fd482ea82c2bafcbeb912d, type: 3}
m_Name:
m_EditorClassIdentifier:
maxHealth: 50
passDamageDataOnDeath: 0
broadcastKillOnDeath: 1
weldable: 0
knifeable: 1
destroyOnDeath: 1
minDamageForSound: 0
loopEffectBelowPercent: 0
loopingDamageEffect: {fileID: 0}
canResurrect: 0
--- !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: 11500000, guid: df4563dc669f9794796a4ad61212cb60, type: 3}
m_Name: Ermshark Egg
m_EditorClassIdentifier:
_liveMixin: {fileID: -9216567195626357826}
prefab: {fileID: 7988108974593223574, guid: eacf6618697b64245b8b7d5d893bd426, type: 3}
loader:
id: 0
classId: ermsharkEgg
displayName: Ermshark Egg
tooltip: '[PH] Ermy shark, do do do do do do
<size=75%>(Model by Toasted3)</size>'
icon: {fileID: 21300000, guid: 2bb9565d9156188479062181f1d9cf48, type: 3}
itemSize: {x: 1, y: 1}
isCraftable: 0
isBuildable: 0
craftingTime: 2.5
pdaEncyInfo: {fileID: 0}
knownTechInfo: {fileID: 0}
spawnData: {fileID: 0}
unlockAtStart: 1
registerInSN: 1
recipeSN: {fileID: 0}
craftTreeTypeSN: 0
craftTreePathSN:
techGroupSN: 14
techCategorySN: -1
requiredForUnlockSN:
isCustom: 0
techType: 0
itemData: {fileID: 0}
equipmentTypeSN: 0
quickSlotTypeSN: 0
registerInBZ: 1
recipeBZ: {fileID: 0}
canBeRecycledBZ: 1
craftTreeTypeBZ: 0
craftTreePathBZ:
techGroupBZ: 13
techCategoryBZ: -1
soundTypeBZ: 15
requiredForUnlockBZ:
isCustom: 0
techType: 0
itemData: {fileID: 0}
equipmentTypeBZ: 0
quickSlotTypeBZ: 0
coldResistanceBZ: 0
references:
version: 1
00000000:
type: {class: ItemLoader, ns: SCHIZO.Items, asm: SCHIZO}
8 changes: 8 additions & 0 deletions Unity/Assets/Mod/Ermshark/Ermshark Egg.asset.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 58d049a

Please sign in to comment.