Initial commit

This commit is contained in:
2026-01-21 23:51:53 +01:00
commit 60b208fee0
1703 changed files with 100223 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>AvailableLibraries</key>
<array>
<dict>
<key>BinaryPath</key>
<string>libGodotFmod.ios.template_release.universal.dylib</string>
<key>LibraryIdentifier</key>
<string>ios-arm64</string>
<key>LibraryPath</key>
<string>libGodotFmod.ios.template_release.universal.dylib</string>
<key>SupportedArchitectures</key>
<array>
<string>arm64</string>
</array>
<key>SupportedPlatform</key>
<string>ios</string>
</dict>
</array>
<key>CFBundlePackageType</key>
<string>XFWK</string>
<key>XCFrameworkFormatVersion</key>
<string>1.0</string>
</dict>
</plist>

View File

@@ -0,0 +1,17 @@
[gd_resource type="StandardMaterial3D" load_steps=4 format=3 uid="uid://cqjolmi3t5evp"]
[ext_resource type="Texture2D" uid="uid://c5t7tmsxfmbp2" path="res://assets/3D/Sample1_MetalGalvanizedSteelWorn001_COL_2K_METALNESS.jpg" id="1_iuy64"]
[ext_resource type="Texture2D" uid="uid://n62yh1j6sxay" path="res://assets/3D/Sample1_MetalGalvanizedSteelWorn001_METALNESS_2K_METALNESS_jpg-MetalGalvanizedSteelWorn001_ROUGHNESS_2K_METALNESS_jpg.png" id="2_6yo53"]
[ext_resource type="Texture2D" uid="uid://d4dl8qkat53mg" path="res://assets/3D/Sample1_MetalGalvanizedSteelWorn001_NRM16_2K_METALNESS_tif.png" id="3_bssyf"]
[resource]
resource_name = "MetalGalvanizedSteelWorn001_2K"
cull_mode = 2
albedo_texture = ExtResource("1_iuy64")
metallic = 1.0
metallic_texture = ExtResource("2_6yo53")
metallic_texture_channel = 2
roughness_texture = ExtResource("2_6yo53")
roughness_texture_channel = 1
normal_enabled = true
normal_texture = ExtResource("3_bssyf")

View File

@@ -0,0 +1,53 @@
extends BasicRoom
class_name Generator
@onready var SocketL: Area3D = $SocketL
@onready var SocketR: Area3D = $SocketR
@onready var SocketLPivot: Node3D = $SocketL/CellPivot
@onready var SocketRPivot: Node3D = $SocketR/CellPivot
var SocketLPowerCell: GrabableObject
var SocketRPowerCell: GrabableObject
func _process(_delta: float) -> void:
if SocketLPowerCell:
if SocketLPowerCell.isGrabbed:
SocketLPowerCell = null
if SocketRPowerCell:
if SocketRPowerCell.isGrabbed:
SocketRPowerCell = null
grabCell(SocketL,SocketLPowerCell,SocketLPivot)
grabCell(SocketR,SocketRPowerCell,SocketRPivot)
if !SpaceshipLogicRef: return
if !SocketLPowerCell and !SocketRPowerCell:
SpaceshipLogicRef.power = false
SpaceshipLogicRef.updateLights()
else:
SpaceshipLogicRef.power = true
SpaceshipLogicRef.updateLights()
func grabCell(Socket: Area3D, SocketCell: GrabableObject, SocketPivot: Node3D):
if Socket.has_overlapping_areas() and !SocketCell:
var potentialCell = getPowerCells(Socket)
if potentialCell: potentialCell = potentialCell.obj
else: return
if potentialCell.freeze == true: return
if !potentialCell.isGrabbed:
SocketCell = potentialCell
if Socket == SocketL: SocketLPowerCell = potentialCell
elif Socket == SocketR: SocketRPowerCell = potentialCell
SocketCell.freeze = true
SocketCell.global_position = SocketPivot.global_position
SocketCell.global_rotation = SocketPivot.global_rotation
func getPowerCells(Area: Area3D) -> GrabBox:
var overlappingAreas: Array[Area3D] = Area.get_overlapping_areas()
for a in overlappingAreas:
if typeof(a == GrabBox):
if a.type == "PowerCell":
return a
return null