commit e446938ba7d72dbc159e6da5d4301b731be3bae5 Author: Ultrablob Date: Tue Apr 16 20:29:45 2024 -0400 initial commit diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000..74293aa Binary files /dev/null and b/.DS_Store differ diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..8ad74f7 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Normalize EOL for all files that Git considers text files. +* text=auto eol=lf diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4709183 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +# Godot 4+ specific ignores +.godot/ diff --git a/Arrow (1).png b/Arrow (1).png new file mode 100644 index 0000000..9699b64 Binary files /dev/null and b/Arrow (1).png differ diff --git a/Arrow (1).png.import b/Arrow (1).png.import new file mode 100644 index 0000000..b8724ec --- /dev/null +++ b/Arrow (1).png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cyk2dqt7ipjg1" +path="res://.godot/imported/Arrow (1).png-f7829071ab4d36b28f9cf326802d31fe.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Arrow (1).png" +dest_files=["res://.godot/imported/Arrow (1).png-f7829071ab4d36b28f9cf326802d31fe.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Circle.png b/Circle.png new file mode 100644 index 0000000..cdb6a9d Binary files /dev/null and b/Circle.png differ diff --git a/Circle.png.import b/Circle.png.import new file mode 100644 index 0000000..277b0d5 --- /dev/null +++ b/Circle.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cso5ufbf7u7oj" +path="res://.godot/imported/Circle.png-5aa705d158b14b9f860407e6f23b289d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Circle.png" +dest_files=["res://.godot/imported/Circle.png-5aa705d158b14b9f860407e6f23b289d.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Clock.gd b/Clock.gd new file mode 100644 index 0000000..c269bc5 --- /dev/null +++ b/Clock.gd @@ -0,0 +1,35 @@ +extends CharacterBody2D + +@export var speed = 250.0 + +func _ready(): + velocity = Vector2(speed, speed) + +func _physics_process(delta): + if get_last_slide_collision(): + var collision: KinematicCollision2D = get_last_slide_collision() + if collision.get_collider(): + hit(collision.get_collider()) + velocity = velocity.bounce(clamp_to_1bit(collision.get_normal())) + + move_and_slide() + +func clamp_to_1bit(normal: Vector2): + var normals = [Vector2(1, 0), Vector2(0, 1), Vector2(-1, 0), Vector2(0, -1)] + var closest_normal = normals[0] + var max_dot_product = normal.dot(closest_normal) + + for i in range(1, normals.size()): + var dot_product = normal.dot(normals[i]) + if dot_product > max_dot_product: + max_dot_product = dot_product + closest_normal = normals[i] + + return closest_normal + +func hit(body): + if body.is_in_group("destructible"): + if body.has_method("destroy"): + body.destroy() + else: + body.queue_free() diff --git a/CollisionCheck.gd b/CollisionCheck.gd new file mode 100644 index 0000000..1fc4e1a --- /dev/null +++ b/CollisionCheck.gd @@ -0,0 +1,11 @@ +extends ShapeCast2D + +func is_clear(area: Vector2): + position = area + force_shapecast_update() + return get_collision_count() == 0 + +func flash(): + $Sprite2D.visible = true + await get_tree().create_timer(0.2).timeout # waits for .2 seconds + $Sprite2D.visible = false diff --git a/Countdown.gd b/Countdown.gd new file mode 100644 index 0000000..b890794 --- /dev/null +++ b/Countdown.gd @@ -0,0 +1,29 @@ +extends Label +var target_time = null + +func _on_request_completed(result, response_code, headers, body): + var json = JSON.parse_string(body.get_string_from_utf8()) + print(json) + if json and "timestamp" in json: + target_time = json["timestamp"] + +# Called when the node enters the scene tree for the first time. +func _ready(): + update_time() + +func update_time(): + target_time = null + $HTTPRequest.request_completed.connect(_on_request_completed) + $HTTPRequest.request("https://flask-hello-world-nine-psi.vercel.app") + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + if target_time: + var time_remaining = target_time - Time.get_unix_time_from_system() + 3600 * 4 # correct for EDT timezone + if time_remaining < 0: + update_time() + var remaining_minutes = floor(time_remaining / 60) + var remaining_seconds = int(time_remaining) % 60 + text = "%d:%02d" % [remaining_minutes, remaining_seconds] + else: + text = "Loading" diff --git a/Entagon.gd b/Entagon.gd new file mode 100644 index 0000000..c903676 --- /dev/null +++ b/Entagon.gd @@ -0,0 +1,17 @@ +extends RigidBody2D + +@onready var player = $"../Player" + +func hit(body): + if body.is_in_group("destructible"): + if body.has_method("destroy"): + body.destroy() + else: + body.queue_free() + queue_free() + if body.name == "Border": + queue_free() + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _physics_process(delta): + apply_central_force((global_position - player.global_position).normalized() * -300) diff --git a/FillScreen.gd b/FillScreen.gd new file mode 100644 index 0000000..c988a4a --- /dev/null +++ b/FillScreen.gd @@ -0,0 +1,11 @@ +extends Label + + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + size = get_viewport().size diff --git a/GameManager.gd b/GameManager.gd new file mode 100644 index 0000000..cfd9d93 --- /dev/null +++ b/GameManager.gd @@ -0,0 +1,15 @@ +extends Node2D + + +func _ready(): + process_mode = Node.PROCESS_MODE_ALWAYS + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + pass + +func _input(event): + if event.is_action_pressed("restart"): + get_tree().paused = false + get_tree().reload_current_scene() diff --git a/GravityGrapple.gd b/GravityGrapple.gd new file mode 100644 index 0000000..cdf7950 --- /dev/null +++ b/GravityGrapple.gd @@ -0,0 +1,27 @@ +extends RayCast2D + +var active = false +@export var force = -1000 + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _physics_process(delta): + if active: + $Marker2D.node.apply_central_force(($Marker2D.node.global_position - global_position).normalized() * force) + $"..".apply_central_force((global_position - $Marker2D.node.global_position).normalized() * force) + +func _input(event): + if event.is_action_pressed("shoot"): + if (not is_colliding()) or (not get_collider() is RigidBody2D): + return + $Line2D.visible = true + active = true + $Marker2D.node = get_collider() + $Marker2D.offset = get_collider().global_position - get_collision_point() + elif event.is_action_released("shoot"): + $Line2D.visible = false + active = false diff --git a/Gun.gd b/Gun.gd new file mode 100644 index 0000000..471e5b3 --- /dev/null +++ b/Gun.gd @@ -0,0 +1,11 @@ +extends Marker2D + +@export var bullet: PackedScene + +func shoot(): + print("Shooting") + var node = bullet.instantiate() + node.global_position = global_position + node.linear_velocity = Vector2(500, 0).rotated(global_rotation) + print(node.linear_velocity) + $/root/Node2D.add_child(node) diff --git a/Hexagon outline.png b/Hexagon outline.png new file mode 100644 index 0000000..a1f50b0 Binary files /dev/null and b/Hexagon outline.png differ diff --git a/Hexagon outline.png.import b/Hexagon outline.png.import new file mode 100644 index 0000000..b289e7c --- /dev/null +++ b/Hexagon outline.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://xq1dd6w22i6f" +path="res://.godot/imported/Hexagon outline.png-ad717813cdc35ccaddcd417e4a24f3ba.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Hexagon outline.png" +dest_files=["res://.godot/imported/Hexagon outline.png-ad717813cdc35ccaddcd417e4a24f3ba.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Hexagon.png b/Hexagon.png new file mode 100644 index 0000000..620f0d8 Binary files /dev/null and b/Hexagon.png differ diff --git a/Hexagon.png.import b/Hexagon.png.import new file mode 100644 index 0000000..acdd479 --- /dev/null +++ b/Hexagon.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://baaak3ooc6rvq" +path="res://.godot/imported/Hexagon.png-1b862bf89e6b7922fd88f522a8d27f58.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Hexagon.png" +dest_files=["res://.godot/imported/Hexagon.png-1b862bf89e6b7922fd88f522a8d27f58.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/InfiniteGradient.gd b/InfiniteGradient.gd new file mode 100644 index 0000000..52b8778 --- /dev/null +++ b/InfiniteGradient.gd @@ -0,0 +1,14 @@ +extends TextureRect + +@export var speed = 30 + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + var move_amount = delta * speed + self.size.x += move_amount + self.position.x -= move_amount diff --git a/Laser.gd b/Laser.gd new file mode 100644 index 0000000..106dcfc --- /dev/null +++ b/Laser.gd @@ -0,0 +1,14 @@ +extends Line2D + +# Called when the node enters the scene tree for the first time. +func _ready(): + modulate = Color(Color.WHITE, 0.2) + pass # Replace with function body. + +func fire(): + $VisibleTimer.start() + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + #print(points) + points[1] = to_local($RayCast2D.get_collision_point()) diff --git a/Leaderboard.gd b/Leaderboard.gd new file mode 100644 index 0000000..a8217c5 --- /dev/null +++ b/Leaderboard.gd @@ -0,0 +1,58 @@ +extends Label + +@export var stopwatch: Stopwatch + +func get_scores(): + $HTTPRequest.request("https://flask-hello-world-nine-psi.vercel.app/leaderboard") + +func submit_score(): + var encrypted_score = "EGH" + Marshalls.utf8_to_base64(str(stopwatch.time_elapsed)) + print(encrypted_score) + $HTTPRequest.request_completed.connect(_on_request_completed) + $HTTPRequest.request("https://flask-hello-world-nine-psi.vercel.app/leaderboard?score=%s" % encrypted_score, [], HTTPClient.METHOD_POST) + +func _on_request_completed(result, response_code, headers, body): + if body.get_string_from_utf8() == "OK": + get_scores() + return true + var json = JSON.parse_string(body.get_string_from_utf8()) + #print(json) + if json and "scores" in json: + var scores = json["scores"] + #print(scores) + var score = stopwatch.time_elapsed + var placement = closest(score, scores) + print(placement) + print(len(scores)) + + if placement < 50: + text = "You placed #%d\n" % [placement] + else: + text = "You placed top %d%%\n" % [(float(placement) / len(scores)) * 100] + var n = 1 + while n <= 5 and n <= len(scores): + text += "%d. %s\n" % [ n, seconds2mmss(scores[n-1]) ] + n += 1 + +func closest(my_number:int, my_array:Array)->int: + # Initialize + var closest_num:int + var closest_delta:int = 0 + var closest_idx = -1 + var temp_delta:int = 0 + # Loop through entire array + for i in range(my_array.size()): + if my_array[i] == my_number: return my_array[i] # exact match found! + temp_delta = int(abs(my_array[i]-my_number)) + if closest_delta == 0 or temp_delta < closest_delta: + closest_num = my_array[i] + closest_idx = i + closest_delta = temp_delta + # Return closest number found + return closest_idx + +func seconds2mmss(total_seconds: float) -> String: + var seconds: float = fmod(total_seconds , 60.0) + var minutes: int = int(total_seconds / 60.0) % 60 + var hhmmss_string: String = "%02d:%05.2f" % [minutes, seconds] + return hhmmss_string diff --git a/Leaderborad.gd b/Leaderborad.gd new file mode 100644 index 0000000..d6c1e3d --- /dev/null +++ b/Leaderborad.gd @@ -0,0 +1,11 @@ +extends Label + + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + pass diff --git a/LockedRotation.gd b/LockedRotation.gd new file mode 100644 index 0000000..910c28d --- /dev/null +++ b/LockedRotation.gd @@ -0,0 +1,5 @@ +extends CollisionShape2D + +# Called every physics frame. 'delta' is the elapsed time since the previous frame. +func _physics_process(delta): + global_rotation = 0 diff --git a/Notification.gd b/Notification.gd new file mode 100644 index 0000000..b228ec1 --- /dev/null +++ b/Notification.gd @@ -0,0 +1,9 @@ +extends Label + + +func notify(notification_text): + text = notification_text + modulate = Color.WHITE + var tween = get_tree().create_tween() + + tween.tween_property(self, "modulate", Color.TRANSPARENT, 1).set_ease(Tween.EASE_OUT) diff --git a/Pentagon.png b/Pentagon.png new file mode 100644 index 0000000..3506494 Binary files /dev/null and b/Pentagon.png differ diff --git a/Pentagon.png.import b/Pentagon.png.import new file mode 100644 index 0000000..278890e --- /dev/null +++ b/Pentagon.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://3y48ijiv4vlf" +path="res://.godot/imported/Pentagon.png-7ed5bfa4e2087f30c59e5bfaa438c497.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Pentagon.png" +dest_files=["res://.godot/imported/Pentagon.png-7ed5bfa4e2087f30c59e5bfaa438c497.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/PinnedLine.gd b/PinnedLine.gd new file mode 100644 index 0000000..606cc5d --- /dev/null +++ b/PinnedLine.gd @@ -0,0 +1,14 @@ +extends Line2D + +@export var point_a: Node2D +@export var point_b: Node2D + +# Called when the node enters the scene tree for the first time. +func _ready(): + top_level = true + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + points[0] = point_a.global_position + points[1] = point_b.global_position diff --git a/PinnedNode.gd b/PinnedNode.gd new file mode 100644 index 0000000..8e6e2d7 --- /dev/null +++ b/PinnedNode.gd @@ -0,0 +1,14 @@ +extends Node2D + +@export var offset = Vector2.ZERO +@export var node: Node2D + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + if node: + global_position = node.global_position - offset diff --git a/Player.gd b/Player.gd new file mode 100644 index 0000000..c88f9f5 --- /dev/null +++ b/Player.gd @@ -0,0 +1,71 @@ +extends RigidBody2D + +var speed = 1000 # move speed in pixels/sec +var rotation_speed = 3 # turning speed in radians/sec +var quare = preload("res://quare.tscn") +var exagon = preload("res://exagon.tscn") +@onready var notifier = $"../Notification" +var num_quares = 0 +var max_quares = 3 +var exagons = 1 + +func _ready(): + update_display() + +func _physics_process(delta): + look_at(get_global_mouse_position()) + var move_input = Input.get_axis("down", "up") + var side_input = Input.get_axis("right", "left") + apply_central_force(transform.y * side_input * speed / 2 + transform.x * move_input * speed) + +func _input(event): + if event.is_action_pressed("jump"): + global_position = get_global_mouse_position() + if event.is_action_pressed("quare"): + if num_quares >= max_quares: + notifier.notify("All Quares in Use!") + return + + if not $"../CollisionCheck".is_clear(get_global_mouse_position()): + $"../CollisionCheck".flash() + notifier.notify("Too Close!") + return + num_quares += 1 + var new_quare = quare.instantiate() + new_quare.position = get_global_mouse_position() + $/root/Node2D.add_child(new_quare) + new_quare.name = "Quare" + update_display() + if event.is_action_pressed("exagon"): + if exagons <= 0: + notifier.notify("No Exagons!") + return + + if not $"../CollisionCheck".is_clear(get_global_mouse_position()): + $"../CollisionCheck".flash() + notifier.notify("Too Close!") + return + exagons -= 1 + var new_exagon = exagon.instantiate() + new_exagon.position = get_global_mouse_position() + $/root/Node2D.add_child(new_exagon) + new_exagon.name = "Exagon" + update_display() + #$Gun.shoot() + +func aquire_quare(): + await get_tree().create_timer(3).timeout + num_quares -= 1 + update_display() + +func aquire_exagon(): + await get_tree().create_timer(15).timeout + exagons += 1 + update_display() + +func update_display(): + $"../UI/Quare Count".text = "%d Quares\n%d Exagons" % [(max_quares - num_quares), exagons] + +func destroy(): + get_tree().paused = true + $"../GameOver".visible = true diff --git a/Preahvihear/OFL.txt b/Preahvihear/OFL.txt new file mode 100644 index 0000000..7c0ca32 --- /dev/null +++ b/Preahvihear/OFL.txt @@ -0,0 +1,93 @@ +Copyright 2019 The Preahvihear Project Authors (https://github.com/danhhong/Preahvihear) + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +https://openfontlicense.org + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/Preahvihear/Preahvihear-Regular.ttf b/Preahvihear/Preahvihear-Regular.ttf new file mode 100644 index 0000000..f629fac Binary files /dev/null and b/Preahvihear/Preahvihear-Regular.ttf differ diff --git a/Preahvihear/Preahvihear-Regular.ttf.import b/Preahvihear/Preahvihear-Regular.ttf.import new file mode 100644 index 0000000..d2b30d4 --- /dev/null +++ b/Preahvihear/Preahvihear-Regular.ttf.import @@ -0,0 +1,33 @@ +[remap] + +importer="font_data_dynamic" +type="FontFile" +uid="uid://dsw5w316y4v54" +path="res://.godot/imported/Preahvihear-Regular.ttf-fe12a5de018003b711dd7856f0e35e17.fontdata" + +[deps] + +source_file="res://Preahvihear/Preahvihear-Regular.ttf" +dest_files=["res://.godot/imported/Preahvihear-Regular.ttf-fe12a5de018003b711dd7856f0e35e17.fontdata"] + +[params] + +Rendering=null +antialiasing=1 +generate_mipmaps=false +multichannel_signed_distance_field=false +msdf_pixel_range=8 +msdf_size=48 +allow_system_fallback=true +force_autohinter=false +hinting=1 +subpixel_positioning=1 +oversampling=0.0 +Fallbacks=null +fallbacks=[] +Compress=null +compress=true +preload=[] +language_support={} +script_support={} +opentype_features={} diff --git a/ScreenPosCamera.gd b/ScreenPosCamera.gd new file mode 100644 index 0000000..1387846 --- /dev/null +++ b/ScreenPosCamera.gd @@ -0,0 +1,11 @@ +extends Camera2D + + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + position = get_viewport().position diff --git a/Shield.gd b/Shield.gd new file mode 100644 index 0000000..ac6f6a0 --- /dev/null +++ b/Shield.gd @@ -0,0 +1,15 @@ +extends StaticBody2D + +@export var health = 10 +var max_health = 10.0 + +func destroy(): + health -= 1 + + if health <= 0: + if not is_queued_for_deletion(): + $"../../Player".aquire_exagon() + $"..".queue_free() + + modulate = Color(Color.CYAN, 0.7 - lerp(0.7, 0.1, health / max_health)) + diff --git a/Spawner.gd b/Spawner.gd new file mode 100644 index 0000000..69c1643 --- /dev/null +++ b/Spawner.gd @@ -0,0 +1,15 @@ +extends Marker2D + +@export var item: PackedScene +@export var random_on_screen = false + +func spawn(): + for i in range(10): + var test_pos = Vector2(randf(), randf()) * Vector2(1920, 1080) + if not $"../CollisionCheck".is_clear(test_pos): + continue + var node = item.instantiate() + node.global_position = test_pos + print(node.global_position) + $/root/Node2D.add_child(node) + break diff --git a/Stopwatch.gd b/Stopwatch.gd new file mode 100644 index 0000000..d36fd22 --- /dev/null +++ b/Stopwatch.gd @@ -0,0 +1,16 @@ +extends Label +class_name Stopwatch + +var time_elapsed: float = 0.0 + +func _process(delta: float) -> void: + if not get_tree().paused: + time_elapsed += delta + text = seconds2hhmmss(time_elapsed) + +func seconds2hhmmss(total_seconds: float) -> String: + #total_seconds = 12345 + var seconds: float = fmod(total_seconds , 60.0) + var minutes: int = int(total_seconds / 60.0) % 60 + var hhmmss_string: String = "%02d:%05.2f" % [minutes, seconds] + return hhmmss_string diff --git a/TextCollision.gd b/TextCollision.gd new file mode 100644 index 0000000..ca883d3 --- /dev/null +++ b/TextCollision.gd @@ -0,0 +1,19 @@ +extends CollisionShape2D + +@onready var font: Font = $"../Label".get_theme_font("font") + +# Called when the node enters the scene tree for the first time. +func _ready(): + update_size() + +func update_size(): + var bbox = font.get_string_size($"../Label".text, HORIZONTAL_ALIGNMENT_LEFT, -1, $"../Label".get_theme_font_size("font_size")) + #print(bbox) + bbox.y /= 2.2 + bbox.x -= 20 + get_shape().extents = bbox / 2 + #print(bbox) + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + update_size() diff --git a/TrajectoryDisplay.gd b/TrajectoryDisplay.gd new file mode 100644 index 0000000..77635f0 --- /dev/null +++ b/TrajectoryDisplay.gd @@ -0,0 +1,14 @@ +extends Line2D + +func _ready(): + $RayCast2D.target_position = $"..".linear_velocity * 5000 + $RayCast2D.force_raycast_update() + +func _physics_process(delta): + #global_rotation = $"..".linear_velocity.angle() + $RayCast2D.target_position = $"..".linear_velocity * 5000 + points[1] = $"..".linear_velocity * 5000 + if $RayCast2D.get_collider() != null and $RayCast2D.get_collider().name == "Player": + visible = true + else: + visible = false diff --git a/Triangle.png b/Triangle.png new file mode 100644 index 0000000..b20e7e1 Binary files /dev/null and b/Triangle.png differ diff --git a/Triangle.png.import b/Triangle.png.import new file mode 100644 index 0000000..46ea627 --- /dev/null +++ b/Triangle.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cartrcqnympin" +path="res://.godot/imported/Triangle.png-c25f011309dbe36c17c05935f6be0fb3.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Triangle.png" +dest_files=["res://.godot/imported/Triangle.png-c25f011309dbe36c17c05935f6be0fb3.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/WorldBorder.gd b/WorldBorder.gd new file mode 100644 index 0000000..1bbc769 --- /dev/null +++ b/WorldBorder.gd @@ -0,0 +1,18 @@ +extends CollisionShape2D + +enum AXIS {X, Y} + +@export var match_axis = AXIS.X + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + var size = get_viewport().size + if match_axis == AXIS.X: + self.position.x = size.x + elif match_axis == AXIS.Y: + self.position.y = size.y diff --git a/addons/.DS_Store b/addons/.DS_Store new file mode 100644 index 0000000..7d35927 Binary files /dev/null and b/addons/.DS_Store differ diff --git a/addons/godot-git-plugin/.DS_Store b/addons/godot-git-plugin/.DS_Store new file mode 100644 index 0000000..97c1893 Binary files /dev/null and b/addons/godot-git-plugin/.DS_Store differ diff --git a/addons/godot-git-plugin/LICENSE b/addons/godot-git-plugin/LICENSE new file mode 100644 index 0000000..f153fb8 --- /dev/null +++ b/addons/godot-git-plugin/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2016-2023 The Godot Engine community + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/addons/godot-git-plugin/THIRDPARTY.md b/addons/godot-git-plugin/THIRDPARTY.md new file mode 100644 index 0000000..837488f --- /dev/null +++ b/addons/godot-git-plugin/THIRDPARTY.md @@ -0,0 +1,1349 @@ +# Third-Party Notices + +The Godot Git Plugin source code uses the following third-party source code: + +1. godotengine/godot-cpp - MIT License - https://github.com/godotengine/godot-cpp/tree/02336831735fd6affbe0a6fa252ec98d3e78120c +2. libgit2/libgit2 - GPLv2 with a special Linking Exception - https://github.com/libgit2/libgit2/tree/b7bad55e4bb0a285b073ba5e02b01d3f522fc95d +3. libssh2/libssh2 - BSD-3-Clause License - https://github.com/libssh2/libssh2/tree/635caa90787220ac3773c1d5ba11f1236c22eae8 + +We also link to these third-party libraries (only in the compiled binary form): + +1. OpenSSL - Only on Linux and MacOS - OpenSSL License - http://www.openssl.org/source/openssl-1.1.1s.tar.gz + +## License Texts + +### godotengine/godot-cpp + +``` +# MIT License + +Copyright (c) 2017-2022 Godot Engine contributors. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +``` + +### libgit2/libgit2 + +``` + libgit2 is Copyright (C) the libgit2 contributors, + unless otherwise stated. See the AUTHORS file for details. + + Note that the only valid version of the GPL as far as this project + is concerned is _this_ particular version of the license (ie v2, not + v2.2 or v3.x or whatever), unless explicitly otherwise stated. + +---------------------------------------------------------------------- + + LINKING EXCEPTION + + In addition to the permissions in the GNU General Public License, + the authors give you unlimited permission to link the compiled + version of this library into combinations with other programs, + and to distribute those combinations without any restriction + coming from the use of this file. (The General Public License + restrictions do apply in other respects; for example, they cover + modification of the file, and distribution when not linked into + a combined executable.) + +---------------------------------------------------------------------- + + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. + +---------------------------------------------------------------------- + +The bundled ZLib code is licensed under the ZLib license: + +Copyright (C) 1995-2010 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +---------------------------------------------------------------------- + +The Clar framework is licensed under the ISC license: + +Copyright (c) 2011-2015 Vicent Marti + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +---------------------------------------------------------------------- + +The regex library (deps/regex/) is licensed under the GNU LGPL +(available at the end of this file). + +Definitions for data structures and routines for the regular +expression library. + +Copyright (C) 1985,1989-93,1995-98,2000,2001,2002,2003,2005,2006,2008 +Free Software Foundation, Inc. +This file is part of the GNU C Library. + +The GNU C Library is free software; you can redistribute it and/or +modify it under the terms of the GNU Lesser General Public +License as published by the Free Software Foundation; either +version 2.1 of the License, or (at your option) any later version. + +The GNU C Library is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public +License along with the GNU C Library; if not, write to the Free +Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +---------------------------------------------------------------------- + +The bundled winhttp definition files (deps/winhttp/) are licensed under +the GNU LGPL (available at the end of this file). + +Copyright (C) 2007 Francois Gouget + +This library is free software; you can redistribute it and/or +modify it under the terms of the GNU Lesser General Public +License as published by the Free Software Foundation; either +version 2.1 of the License, or (at your option) any later version. + +This library is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public +License along with this library; if not, write to the Free Software +Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + +---------------------------------------------------------------------- + + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! + +---------------------------------------------------------------------- + +The bundled SHA1 collision detection code is licensed under the MIT license: + +MIT License + +Copyright (c) 2017: + Marc Stevens + Cryptology Group + Centrum Wiskunde & Informatica + P.O. Box 94079, 1090 GB Amsterdam, Netherlands + marc@marc-stevens.nl + + Dan Shumow + Microsoft Research + danshu@microsoft.com + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +---------------------------------------------------------------------- + +The bundled wildmatch code is licensed under the BSD license: + +Copyright Rich Salz. +All rights reserved. + +Redistribution and use in any form are permitted provided that the +following restrictions are are met: + +1. Source distributions must retain this entire copyright notice + and comment. +2. Binary distributions must include the acknowledgement ``This + product includes software developed by Rich Salz'' in the + documentation or other materials provided with the + distribution. This must not be represented as an endorsement + or promotion without specific prior written permission. +3. The origin of this software must not be misrepresented, either + by explicit claim or by omission. Credits must appear in the + source and documentation. +4. Altered versions must be plainly marked as such in the source + and documentation and must not be misrepresented as being the + original software. + +THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED +WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. + +---------------------------------------------------------------------- + +Portions of the OpenSSL headers are included under the OpenSSL license: + +Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) +All rights reserved. + +This package is an SSL implementation written +by Eric Young (eay@cryptsoft.com). +The implementation was written so as to conform with Netscapes SSL. + +This library is free for commercial and non-commercial use as long as +the following conditions are aheared to. The following conditions +apply to all code found in this distribution, be it the RC4, RSA, +lhash, DES, etc., code; not just the SSL code. The SSL documentation +included with this distribution is covered by the same copyright terms +except that the holder is Tim Hudson (tjh@cryptsoft.com). + +Copyright remains Eric Young's, and as such any Copyright notices in +the code are not to be removed. +If this package is used in a product, Eric Young should be given attribution +as the author of the parts of the library used. +This can be in the form of a textual message at program startup or +in documentation (online or textual) provided with the package. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +1. Redistributions of source code must retain the copyright + notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +3. All advertising materials mentioning features or use of this software + must display the following acknowledgement: + "This product includes cryptographic software written by + Eric Young (eay@cryptsoft.com)" + The word 'cryptographic' can be left out if the rouines from the library + being used are not cryptographic related :-). +4. If you include any Windows specific code (or a derivative thereof) from + the apps directory (application code) you must include an acknowledgement: + "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" + +THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. + +The licence and distribution terms for any publically available version or +derivative of this code cannot be changed. i.e. this code cannot simply be +copied and put under another distribution licence +[including the GNU Public Licence.] + +==================================================================== +Copyright (c) 1998-2007 The OpenSSL Project. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + +3. All advertising materials mentioning features or use of this + software must display the following acknowledgment: + "This product includes software developed by the OpenSSL Project + for use in the OpenSSL Toolkit. (http://www.openssl.org/)" + +4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to + endorse or promote products derived from this software without + prior written permission. For written permission, please contact + openssl-core@openssl.org. + +5. Products derived from this software may not be called "OpenSSL" + nor may "OpenSSL" appear in their names without prior written + permission of the OpenSSL Project. + +6. Redistributions of any form whatsoever must retain the following + acknowledgment: + "This product includes software developed by the OpenSSL Project + for use in the OpenSSL Toolkit (http://www.openssl.org/)" + +THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY +EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR +ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED +OF THE POSSIBILITY OF SUCH DAMAGE. +``` + +### libssh2/libssh2 + +``` +/* Copyright (c) 2004-2007 Sara Golemon + * Copyright (c) 2005,2006 Mikhail Gusarov + * Copyright (c) 2006-2007 The Written Word, Inc. + * Copyright (c) 2007 Eli Fant + * Copyright (c) 2009-2021 Daniel Stenberg + * Copyright (C) 2008, 2009 Simon Josefsson + * Copyright (c) 2000 Markus Friedl + * Copyright (c) 2015 Microsoft Corp. + * All rights reserved. + * + * Redistribution and use in source and binary forms, + * with or without modification, are permitted provided + * that the following conditions are met: + * + * Redistributions of source code must retain the above + * copyright notice, this list of conditions and the + * following disclaimer. + * + * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * Neither the name of the copyright holder nor the names + * of any other contributors may be used to endorse or + * promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND + * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE + * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY + * OF SUCH DAMAGE. + */ +``` + +### OpenSSL + +``` + + LICENSE ISSUES + ============== + + The OpenSSL toolkit stays under a double license, i.e. both the conditions of + the OpenSSL License and the original SSLeay license apply to the toolkit. + See below for the actual license texts. + + OpenSSL License + --------------- + +/* ==================================================================== + * Copyright (c) 1998-2019 The OpenSSL Project. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * 3. All advertising materials mentioning features or use of this + * software must display the following acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" + * + * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to + * endorse or promote products derived from this software without + * prior written permission. For written permission, please contact + * openssl-core@openssl.org. + * + * 5. Products derived from this software may not be called "OpenSSL" + * nor may "OpenSSL" appear in their names without prior written + * permission of the OpenSSL Project. + * + * 6. Redistributions of any form whatsoever must retain the following + * acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit (http://www.openssl.org/)" + * + * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY + * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED + * OF THE POSSIBILITY OF SUCH DAMAGE. + * ==================================================================== + * + * This product includes cryptographic software written by Eric Young + * (eay@cryptsoft.com). This product includes software written by Tim + * Hudson (tjh@cryptsoft.com). + * + */ + + Original SSLeay License + ----------------------- + +/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) + * All rights reserved. + * + * This package is an SSL implementation written + * by Eric Young (eay@cryptsoft.com). + * The implementation was written so as to conform with Netscapes SSL. + * + * This library is free for commercial and non-commercial use as long as + * the following conditions are aheared to. The following conditions + * apply to all code found in this distribution, be it the RC4, RSA, + * lhash, DES, etc., code; not just the SSL code. The SSL documentation + * included with this distribution is covered by the same copyright terms + * except that the holder is Tim Hudson (tjh@cryptsoft.com). + * + * Copyright remains Eric Young's, and as such any Copyright notices in + * the code are not to be removed. + * If this package is used in a product, Eric Young should be given attribution + * as the author of the parts of the library used. + * This can be in the form of a textual message at program startup or + * in documentation (online or textual) provided with the package. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * "This product includes cryptographic software written by + * Eric Young (eay@cryptsoft.com)" + * The word 'cryptographic' can be left out if the rouines from the library + * being used are not cryptographic related :-). + * 4. If you include any Windows specific code (or a derivative thereof) from + * the apps directory (application code) you must include an acknowledgement: + * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" + * + * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * The licence and distribution terms for any publically available version or + * derivative of this code cannot be changed. i.e. this code cannot simply be + * copied and put under another distribution licence + * [including the GNU Public Licence.] + */ +``` diff --git a/addons/godot-git-plugin/git_plugin.gdextension b/addons/godot-git-plugin/git_plugin.gdextension new file mode 100644 index 0000000..49fffbf --- /dev/null +++ b/addons/godot-git-plugin/git_plugin.gdextension @@ -0,0 +1,12 @@ +[configuration] + +entry_symbol = "git_plugin_init" +compatibility_minimum = "4.1.0" + +[libraries] + +macos.editor = "macos/libgit_plugin.macos.editor.universal.dylib" +windows.editor.x86_64 = "win64/libgit_plugin.windows.editor.x86_64.dll" +linux.editor.x86_64 = "linux/libgit_plugin.linux.editor.x86_64.so" +linux.editor.arm64 = "linux/libgit_plugin.linux.editor.arm64.so" +linux.editor.rv64 = "" diff --git a/addons/godot-git-plugin/linux/libgit_plugin.linux.editor.x86_64.so b/addons/godot-git-plugin/linux/libgit_plugin.linux.editor.x86_64.so new file mode 100644 index 0000000..8dab6db Binary files /dev/null and b/addons/godot-git-plugin/linux/libgit_plugin.linux.editor.x86_64.so differ diff --git a/addons/godot-git-plugin/macos/libgit_plugin.macos.editor.universal.dylib b/addons/godot-git-plugin/macos/libgit_plugin.macos.editor.universal.dylib new file mode 100644 index 0000000..644aa2a Binary files /dev/null and b/addons/godot-git-plugin/macos/libgit_plugin.macos.editor.universal.dylib differ diff --git a/addons/godot-git-plugin/plugin.cfg b/addons/godot-git-plugin/plugin.cfg new file mode 100644 index 0000000..9c4e36f --- /dev/null +++ b/addons/godot-git-plugin/plugin.cfg @@ -0,0 +1,7 @@ +[plugin] + +name="Godot Git Plugin" +description="This plugin lets you interact with Git without leaving the Godot editor. More information can be found at https://github.com/godotengine/godot-git-plugin/wiki" +author="twaritwaikar" +version="v3.1.1" +script="godot-git-plugin.gd" diff --git a/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.dll b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.dll new file mode 100644 index 0000000..47bbb1d Binary files /dev/null and b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.dll differ diff --git a/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.exp b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.exp new file mode 100644 index 0000000..6c68d89 Binary files /dev/null and b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.exp differ diff --git a/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.lib b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.lib new file mode 100644 index 0000000..4537929 Binary files /dev/null and b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.lib differ diff --git a/bullet.gd b/bullet.gd new file mode 100644 index 0000000..7f6a6ff --- /dev/null +++ b/bullet.gd @@ -0,0 +1,18 @@ +extends RigidBody2D + +var bounces = 0 + +func hit(body): + if body.is_in_group("destructible"): + if body.has_method("destroy"): + body.destroy() + else: + body.queue_free() + + queue_free() + else: + bounces += 1 + #print(bounces) + + if bounces >= 2: + queue_free() diff --git a/bullet.tscn b/bullet.tscn new file mode 100644 index 0000000..9cb58d2 --- /dev/null +++ b/bullet.tscn @@ -0,0 +1,61 @@ +[gd_scene load_steps=9 format=3 uid="uid://c6ybtahxwpukd"] + +[ext_resource type="Script" path="res://bullet.gd" id="1_3q13i"] +[ext_resource type="Texture2D" uid="uid://cso5ufbf7u7oj" path="res://Circle.png" id="1_if042"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="2_cbxu4"] +[ext_resource type="Texture2D" uid="uid://djfjdlri5xdkn" path="res://dotted line.png" id="4_h1jno"] +[ext_resource type="Script" path="res://TrajectoryDisplay.gd" id="5_0jcwc"] + +[sub_resource type="PhysicsMaterial" id="PhysicsMaterial_xnhwp"] +friction = 0.0 +bounce = 1.0 + +[sub_resource type="CircleShape2D" id="CircleShape2D_b5cca"] +radius = 13.0 + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_tltp1"] +gradient = ExtResource("2_cbxu4") +width = 1024 + +[node name="Bullet" type="RigidBody2D"] +collision_layer = 2 +physics_material_override = SubResource("PhysicsMaterial_xnhwp") +gravity_scale = 1.66533e-16 +max_contacts_reported = 1 +contact_monitor = true +linear_velocity = Vector2(2.08165e-12, 2.08165e-12) +script = ExtResource("1_3q13i") + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +rotation = -1.5708 +shape = SubResource("CircleShape2D_b5cca") + +[node name="Sprite2D" type="Sprite2D" parent="."] +clip_children = 1 +scale = Vector2(0.05, 0.05) +texture = ExtResource("1_if042") + +[node name="TextureRect" type="TextureRect" parent="Sprite2D"] +offset_left = -280.0 +offset_top = -280.0 +offset_right = 744.0 +offset_bottom = -240.0 +scale = Vector2(1, 13.8) +texture = SubResource("GradientTexture1D_tltp1") + +[node name="TrajectoryDisplay" type="Line2D" parent="."] +z_index = -1 +texture_repeat = 2 +position = Vector2(-2, 0) +points = PackedVector2Array(0, 0, 2000, 2.08165e-12) +width = 50.0 +default_color = Color(0.909804, 0.717647, 0.337255, 0.529412) +texture = ExtResource("4_h1jno") +texture_mode = 1 +script = ExtResource("5_0jcwc") + +[node name="RayCast2D" type="RayCast2D" parent="TrajectoryDisplay"] +target_position = Vector2(5000, 2.08165e-12) +collision_mask = 3 + +[connection signal="body_entered" from="." to="." method="hit"] diff --git a/dotted line.png b/dotted line.png new file mode 100644 index 0000000..601e1a7 Binary files /dev/null and b/dotted line.png differ diff --git a/dotted line.png.import b/dotted line.png.import new file mode 100644 index 0000000..f099a97 --- /dev/null +++ b/dotted line.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://djfjdlri5xdkn" +path="res://.godot/imported/dotted line.png-e957b055d2b4cfff3d51ae09a585a9b8.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://dotted line.png" +dest_files=["res://.godot/imported/dotted line.png-e957b055d2b4cfff3d51ae09a585a9b8.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/elastic.tres b/elastic.tres new file mode 100644 index 0000000..aaf5abb --- /dev/null +++ b/elastic.tres @@ -0,0 +1,5 @@ +[gd_resource type="PhysicsMaterial" format=3 uid="uid://c5tm7od8mwjjb"] + +[resource] +friction = 0.0 +bounce = 1.0 diff --git a/entagon.tscn b/entagon.tscn new file mode 100644 index 0000000..baaaff1 --- /dev/null +++ b/entagon.tscn @@ -0,0 +1,37 @@ +[gd_scene load_steps=6 format=3 uid="uid://c54oi61t8bvtu"] + +[ext_resource type="Script" path="res://Entagon.gd" id="1_726g8"] +[ext_resource type="PhysicsMaterial" uid="uid://c5tm7od8mwjjb" path="res://elastic.tres" id="1_pvpk5"] +[ext_resource type="Texture2D" uid="uid://3y48ijiv4vlf" path="res://Pentagon.png" id="2_rhkcn"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="3_13sdt"] + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_ebpuq"] +gradient = ExtResource("3_13sdt") +width = 2048 + +[node name="Entagon" type="RigidBody2D"] +physics_material_override = ExtResource("1_pvpk5") +gravity_scale = 1.66533e-16 +max_contacts_reported = 2 +contact_monitor = true +linear_damp = 0.1 +angular_velocity = 0.174533 +script = ExtResource("1_726g8") + +[node name="Sprite2D" type="Sprite2D" parent="."] +clip_children = 1 +scale = Vector2(0.1, 0.1) +texture = ExtResource("2_rhkcn") + +[node name="TextureRect" type="TextureRect" parent="Sprite2D"] +offset_left = -1324.0 +offset_top = -301.0 +offset_right = 724.0 +offset_bottom = 242.0 +texture = SubResource("GradientTexture1D_ebpuq") + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."] +scale = Vector2(0.1, 0.1) +polygon = PackedVector2Array(0, -227, 236, -55, 143, 221, -144, 219, -230, -51) + +[connection signal="body_entered" from="." to="." method="hit"] diff --git a/exagon.tscn b/exagon.tscn new file mode 100644 index 0000000..90cc8b3 --- /dev/null +++ b/exagon.tscn @@ -0,0 +1,47 @@ +[gd_scene load_steps=8 format=3 uid="uid://c87easb8570vd"] + +[ext_resource type="PhysicsMaterial" uid="uid://c5tm7od8mwjjb" path="res://elastic.tres" id="1_1oplx"] +[ext_resource type="Script" path="res://Shield.gd" id="2_q7qjq"] +[ext_resource type="Texture2D" uid="uid://xq1dd6w22i6f" path="res://Hexagon outline.png" id="2_x53yb"] +[ext_resource type="Texture2D" uid="uid://baaak3ooc6rvq" path="res://Hexagon.png" id="3_tj1rx"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="4_14wdv"] + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_d2ef1"] +gradient = ExtResource("4_14wdv") +width = 4096 + +[sub_resource type="CircleShape2D" id="CircleShape2D_evq3y"] +radius = 25.0 + +[node name="Exagon" type="Node2D"] + +[node name="Shield" type="StaticBody2D" parent="." groups=["destructible"]] +collision_layer = 2 +collision_mask = 2 +physics_material_override = ExtResource("1_1oplx") +script = ExtResource("2_q7qjq") + +[node name="Sprite" type="Sprite2D" parent="Shield"] +self_modulate = Color(0.529412, 0.819608, 1, 0.27451) +texture = ExtResource("2_x53yb") + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="Shield"] +position = Vector2(13, 194) +polygon = PackedVector2Array(-13, -443, 204, -317, 206, -69, -12, 57, -231, -71, -231, -316) + +[node name="Generator" type="StaticBody2D" parent="."] + +[node name="Sprite" type="Sprite2D" parent="Generator"] +clip_children = 1 +scale = Vector2(0.1, 0.1) +texture = ExtResource("3_tj1rx") + +[node name="TextureRect" type="TextureRect" parent="Generator/Sprite"] +offset_left = -2110.0 +offset_top = -490.0 +offset_right = 1986.0 +offset_bottom = 534.0 +texture = SubResource("GradientTexture1D_d2ef1") + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Generator"] +shape = SubResource("CircleShape2D_evq3y") diff --git a/export_presets.cfg b/export_presets.cfg new file mode 100644 index 0000000..54b95f3 --- /dev/null +++ b/export_presets.cfg @@ -0,0 +1,37 @@ +[preset.0] + +name="Web" +platform="Web" +runnable=true +dedicated_server=false +custom_features="" +export_filter="all_resources" +include_filter="" +exclude_filter="" +export_path="../Build/index.html" +encryption_include_filters="" +encryption_exclude_filters="" +encrypt_pck=false +encrypt_directory=false + +[preset.0.options] + +custom_template/debug="" +custom_template/release="" +variant/extensions_support=false +vram_texture_compression/for_desktop=true +vram_texture_compression/for_mobile=false +html/export_icon=true +html/custom_html_shell="" +html/head_include="" +html/canvas_resize_policy=2 +html/focus_canvas_on_start=true +html/experimental_virtual_keyboard=false +progressive_web_app/enabled=false +progressive_web_app/offline_page="" +progressive_web_app/display=1 +progressive_web_app/orientation=0 +progressive_web_app/icon_144x144="" +progressive_web_app/icon_180x180="" +progressive_web_app/icon_512x512="" +progressive_web_app/background_color=Color(0, 0, 0, 1) diff --git a/gradient.tres b/gradient.tres new file mode 100644 index 0000000..f09f72d --- /dev/null +++ b/gradient.tres @@ -0,0 +1,7 @@ +[gd_resource type="Gradient" format=3 uid="uid://c41berdx2rqpw"] + +[resource] +offsets = PackedFloat32Array(0.00649351, 0.0625, 0.125, 0.1875, 0.25, 0.3125, 0.375, 0.4375, 0.5, 0.5625, 0.625, 0.6875, 0.75, 0.8125, 0.875, 0.9375, 1) +colors = PackedColorArray(0.901961, 0.168627, 0.658824, 1, 0.890196, 0.188235, 0.34902, 1, 0.886275, 0.254902, 0.254902, 1, 0.945098, 0.45098, 0.239216, 1, 0.988235, 0.858824, 0.392157, 1, 0.286275, 0.886275, 0.356863, 1, 0.188235, 0.8, 0.623529, 1, 0.223529, 0.823529, 0.752941, 1, 0.266667, 0.666667, 0.917647, 1, 0.364706, 0.415686, 0.952941, 1, 0.635294, 0.294118, 0.807843, 1, 0.752941, 0.156863, 0.713726, 1, 0.901961, 0.168627, 0.658824, 1, 0.890196, 0.188235, 0.34902, 1, 0.886275, 0.254902, 0.254902, 1, 0.945098, 0.45098, 0.239216, 1, 0.901961, 0.168627, 0.658824, 1) +metadata/_snap_enabled = true +metadata/_snap_count = 16 diff --git a/icon.svg b/icon.svg new file mode 100644 index 0000000..b370ceb --- /dev/null +++ b/icon.svg @@ -0,0 +1 @@ + diff --git a/icon.svg.import b/icon.svg.import new file mode 100644 index 0000000..a3a2baa --- /dev/null +++ b/icon.svg.import @@ -0,0 +1,37 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dbnms6rydhcxp" +path="res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://icon.svg" +dest_files=["res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/ircle.tscn b/ircle.tscn new file mode 100644 index 0000000..cb358d3 --- /dev/null +++ b/ircle.tscn @@ -0,0 +1,59 @@ +[gd_scene load_steps=7 format=3 uid="uid://4lc6bvf7b8a0"] + +[ext_resource type="Script" path="res://laser_enemy.gd" id="2_lyi2i"] +[ext_resource type="Script" path="res://Laser.gd" id="3_hosl5"] +[ext_resource type="Texture2D" uid="uid://cso5ufbf7u7oj" path="res://Circle.png" id="4_kq1iu"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="5_4gq2q"] + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_cis1o"] +gradient = ExtResource("5_4gq2q") + +[sub_resource type="CircleShape2D" id="CircleShape2D_yns8h"] +radius = 128.0 + +[node name="Ircle" type="StaticBody2D" groups=["destructible"]] +scale = Vector2(0.2, 0.2) +script = ExtResource("2_lyi2i") + +[node name="Line2D" type="Line2D" parent="."] +z_index = -2 +points = PackedVector2Array(0, 0, 5000, 2.08165e-12) +width = 100.0 +default_color = Color(0.886275, 0.254902, 0.254902, 1) +end_cap_mode = 2 +script = ExtResource("3_hosl5") + +[node name="VisibleTimer" type="Timer" parent="Line2D"] +wait_time = 0.2 + +[node name="RayCast2D" type="RayCast2D" parent="Line2D"] +target_position = Vector2(50000, 2.08165e-12) +collision_mask = 3 + +[node name="Sprite2D" type="Sprite2D" parent="."] +clip_children = 1 +scale = Vector2(0.5, 0.5) +texture = ExtResource("4_kq1iu") + +[node name="TextureRect" type="TextureRect" parent="Sprite2D"] +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -1700.0 +offset_top = -370.0 +offset_right = -1700.0 +offset_bottom = -370.0 +grow_horizontal = 2 +grow_vertical = 2 +scale = Vector2(5, 2) +texture = SubResource("GradientTexture1D_cis1o") + +[node name="Timer" type="Timer" parent="."] +wait_time = 3.0 +autostart = true + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +shape = SubResource("CircleShape2D_yns8h") + +[connection signal="timeout" from="Line2D/VisibleTimer" to="Line2D" method="hide_self"] +[connection signal="timeout" from="Timer" to="." method="fire_laser"] diff --git a/laser_enemy.gd b/laser_enemy.gd new file mode 100644 index 0000000..0a3f186 --- /dev/null +++ b/laser_enemy.gd @@ -0,0 +1,50 @@ +extends StaticBody2D + +@onready var player = $"../Player" +var aiming = true + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + if aiming: + look_at(player.global_position) + +func fire_laser(): + var tween = get_tree().create_tween() + + aiming = false + tween.set_parallel(true) + tween.tween_property($Sprite2D/TextureRect, "position", Vector2(-2000, -370), 1).set_ease(Tween.EASE_IN_OUT) + tween.tween_property($Line2D, "modulate", Color.WHITE, 1).set_ease(Tween.EASE_IN) + tween.set_parallel(false) + tween.tween_callback($Line2D.fire) + tween.tween_interval(0.2) + tween.tween_callback(check_player) + tween.set_parallel(true) + tween.tween_property($Line2D, "modulate", Color(Color.WHITE, 0.2), 0.2).set_ease(Tween.EASE_OUT) + tween.tween_property($Sprite2D/TextureRect, "position", Vector2(-1700, -370), 0.5).set_ease(Tween.EASE_IN_OUT) + tween.set_parallel(false) + tween.tween_callback(start_aim) + +func start_aim(): + aiming = true + +func check_player(): + var body = $Line2D/RayCast2D.get_collider() + if body != null and body.is_in_group("destructible"): + if body.has_method("destroy"): + body.destroy() + else: + body.queue_free() + + +func hit(body: Node2D): + if body.name == "Clock": + queue_free() + elif body.name == "Bullet": + body.queue_free() + queue_free() diff --git a/main.tscn b/main.tscn new file mode 100644 index 0000000..1f6ddfb --- /dev/null +++ b/main.tscn @@ -0,0 +1,325 @@ +[gd_scene load_steps=31 format=3 uid="uid://bmd4m7lqj4v0x"] + +[ext_resource type="Script" path="res://InfiniteGradient.gd" id="1_0hjpt"] +[ext_resource type="Script" path="res://TextCollision.gd" id="1_hy18x"] +[ext_resource type="Script" path="res://Spawner.gd" id="1_ifu8g"] +[ext_resource type="Script" path="res://GameManager.gd" id="1_k8sg3"] +[ext_resource type="FontFile" uid="uid://dsw5w316y4v54" path="res://Preahvihear/Preahvihear-Regular.ttf" id="2_0a4qt"] +[ext_resource type="Script" path="res://Countdown.gd" id="2_qroir"] +[ext_resource type="PackedScene" uid="uid://4lc6bvf7b8a0" path="res://ircle.tscn" id="3_7jxvc"] +[ext_resource type="PhysicsMaterial" uid="uid://c5tm7od8mwjjb" path="res://elastic.tres" id="4_bx3xr"] +[ext_resource type="PackedScene" uid="uid://yu50iyftoyaj" path="res://riangle.tscn" id="4_icpv2"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="4_yk0bb"] +[ext_resource type="Script" path="res://Clock.gd" id="5_7po8n"] +[ext_resource type="PackedScene" uid="uid://cgcjicue76wsr" path="res://player.tscn" id="7_ujibo"] +[ext_resource type="Script" path="res://CollisionCheck.gd" id="11_ryeyk"] +[ext_resource type="Texture2D" uid="uid://cso5ufbf7u7oj" path="res://Circle.png" id="13_318fy"] +[ext_resource type="Script" path="res://Notification.gd" id="13_lkv81"] +[ext_resource type="Script" path="res://Stopwatch.gd" id="13_xhnp2"] +[ext_resource type="Script" path="res://Leaderboard.gd" id="14_v1elq"] +[ext_resource type="PackedScene" uid="uid://c54oi61t8bvtu" path="res://entagon.tscn" id="18_jl3xw"] + +[sub_resource type="Gradient" id="Gradient_bi1rk"] +interpolation_mode = 1 +offsets = PackedFloat32Array(0) +colors = PackedColorArray(0.0509804, 0.0509804, 0.0509804, 1) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_f0jwl"] +gradient = SubResource("Gradient_bi1rk") + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_7w8g6"] +size = Vector2(605, 225.5) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_vrv6v"] +gradient = ExtResource("4_yk0bb") +width = 4096 + +[sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_o86fr"] + +[sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_0lugs"] +normal = Vector2(2.08165e-12, 1) + +[sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_nfw1m"] +normal = Vector2(1, 2.08165e-12) + +[sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_wacat"] +normal = Vector2(-1, 2.08165e-12) + +[sub_resource type="CircleShape2D" id="CircleShape2D_bmvvy"] +radius = 50.0 + +[sub_resource type="Gradient" id="Gradient_or5lt"] +colors = PackedColorArray(1, 0, 0, 1, 1, 0, 0, 1) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_cygyn"] +gradient = SubResource("Gradient_or5lt") + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_ky2qs"] +gradient = ExtResource("4_yk0bb") +width = 2048 + +[node name="Node2D" type="Node2D"] +position = Vector2(-2, -1) +script = ExtResource("1_k8sg3") + +[node name="Spawner" type="Marker2D" parent="."] +position = Vector2(1749, 999) +script = ExtResource("1_ifu8g") +item = ExtResource("3_7jxvc") + +[node name="Timer" type="Timer" parent="Spawner"] +wait_time = 3.0 +autostart = true + +[node name="Spawner2" type="Marker2D" parent="."] +position = Vector2(1749, 999) +script = ExtResource("1_ifu8g") +item = ExtResource("4_icpv2") + +[node name="Timer" type="Timer" parent="Spawner2"] +wait_time = 4.0 +autostart = true + +[node name="Spawner3" type="Marker2D" parent="."] +position = Vector2(3498, 1998) +script = ExtResource("1_ifu8g") +item = ExtResource("18_jl3xw") + +[node name="Timer" type="Timer" parent="Spawner3"] +wait_time = 10.0 +autostart = true + +[node name="BG" type="TextureRect" parent="."] +z_index = -1000 +offset_left = 2.0 +offset_top = -5.0 +offset_right = 50002.0 +offset_bottom = 49995.0 +texture = SubResource("GradientTexture1D_f0jwl") + +[node name="Clock" type="CharacterBody2D" parent="."] +position = Vector2(201, 200) +collision_layer = 3 +collision_mask = 3 +motion_mode = 1 +script = ExtResource("5_7po8n") + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Clock"] +position = Vector2(207, 192) +scale = Vector2(0.75, 0.75) +shape = SubResource("RectangleShape2D_7w8g6") +script = ExtResource("1_hy18x") + +[node name="Label" type="Label" parent="Clock"] +clip_children = 2 +clip_contents = true +anchors_preset = 8 +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +offset_left = 57.0 +offset_top = 55.0 +offset_right = 476.0 +offset_bottom = 418.0 +grow_horizontal = 2 +grow_vertical = 2 +scale = Vector2(0.75, 0.75) +size_flags_horizontal = 4 +theme_override_fonts/font = ExtResource("2_0a4qt") +theme_override_font_sizes/font_size = 200 +text = "9:24" +horizontal_alignment = 1 +vertical_alignment = 1 +script = ExtResource("2_qroir") + +[node name="TextureRect" type="TextureRect" parent="Clock/Label"] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +rotation = -6.28319 +texture = SubResource("GradientTexture1D_vrv6v") +stretch_mode = 1 +script = ExtResource("1_0hjpt") + +[node name="HTTPRequest" type="HTTPRequest" parent="Clock/Label"] + +[node name="Border" type="StaticBody2D" parent="."] +physics_material_override = ExtResource("4_bx3xr") + +[node name="Bottom" type="CollisionShape2D" parent="Border"] +position = Vector2(1080, 1080) +shape = SubResource("WorldBoundaryShape2D_o86fr") +one_way_collision_margin = 0.0 + +[node name="Top" type="CollisionShape2D" parent="Border"] +position = Vector2(582, 0) +shape = SubResource("WorldBoundaryShape2D_0lugs") + +[node name="Left" type="CollisionShape2D" parent="Border"] +position = Vector2(0, 330) +shape = SubResource("WorldBoundaryShape2D_nfw1m") + +[node name="Right" type="CollisionShape2D" parent="Border"] +position = Vector2(1920, 330) +shape = SubResource("WorldBoundaryShape2D_wacat") + +[node name="Player" parent="." instance=ExtResource("7_ujibo")] +position = Vector2(110, 74) +scale = Vector2(0.5, 0.5) + +[node name="UI" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_right = 1920.0 +offset_bottom = 1080.0 + +[node name="Quare Count" type="Label" parent="UI"] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 44.0 +offset_top = -137.0 +offset_right = 279.0 +grow_vertical = 0 +theme_override_constants/line_spacing = -30 +theme_override_fonts/font = ExtResource("2_0a4qt") +theme_override_font_sizes/font_size = 50 +text = "2 Quares +1 Exagon" + +[node name="Stopwatch" type="Label" parent="UI"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -268.0 +offset_top = 22.0 +offset_right = -33.0 +offset_bottom = 159.0 +grow_horizontal = 0 +theme_override_fonts/font = ExtResource("2_0a4qt") +theme_override_font_sizes/font_size = 50 +text = "10:00.24" +script = ExtResource("13_xhnp2") + +[node name="GameOver" type="Label" parent="."] +visible = false +z_index = 100 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_right = 1920.0 +offset_bottom = 1080.0 +grow_horizontal = 2 +grow_vertical = 2 +size_flags_horizontal = 4 +theme_override_fonts/font = ExtResource("2_0a4qt") +theme_override_font_sizes/font_size = 200 +text = "Game Over!" +horizontal_alignment = 1 + +[node name="ColorRect" type="ColorRect" parent="GameOver"] +z_index = -1 +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +color = Color(0, 0, 0, 0.372549) + +[node name="GameOver" type="Label" parent="GameOver"] +z_index = 100 +layout_mode = 1 +anchors_preset = 7 +anchor_left = 0.5 +anchor_top = 1.0 +anchor_right = 0.5 +anchor_bottom = 1.0 +offset_left = -293.0 +offset_top = -147.0 +offset_right = 293.0 +offset_bottom = -37.0 +grow_horizontal = 2 +grow_vertical = 0 +theme_override_fonts/font = ExtResource("2_0a4qt") +theme_override_font_sizes/font_size = 60 +text = "Press R to Restart" +horizontal_alignment = 1 +vertical_alignment = 1 + +[node name="Leaderboard" type="Label" parent="GameOver" node_paths=PackedStringArray("stopwatch")] +layout_mode = 1 +anchors_preset = 14 +anchor_top = 0.5 +anchor_right = 1.0 +anchor_bottom = 0.5 +offset_top = -217.0 +offset_bottom = 255.0 +grow_horizontal = 2 +grow_vertical = 2 +theme_override_fonts/font = ExtResource("2_0a4qt") +theme_override_font_sizes/font_size = 50 +text = " +Loading Leaderboard..." +horizontal_alignment = 1 +script = ExtResource("14_v1elq") +stopwatch = NodePath("../../UI/Stopwatch") + +[node name="HTTPRequest" type="HTTPRequest" parent="GameOver/Leaderboard"] + +[node name="CollisionCheck" type="ShapeCast2D" parent="."] +shape = SubResource("CircleShape2D_bmvvy") +target_position = Vector2(2.08165e-12, 2.08165e-12) +collision_mask = 3 +script = ExtResource("11_ryeyk") + +[node name="Sprite2D" type="Sprite2D" parent="CollisionCheck"] +visible = false +self_modulate = Color(1, 0, 0, 0.356863) +clip_children = 1 +scale = Vector2(0.35, 0.35) +texture = ExtResource("13_318fy") + +[node name="TextureRect" type="TextureRect" parent="CollisionCheck/Sprite2D"] +offset_left = -288.0 +offset_top = -288.0 +offset_right = -32.0 +offset_bottom = -248.0 +scale = Vector2(2.19999, 15.1168) +texture = SubResource("GradientTexture1D_cygyn") + +[node name="Notification" type="Label" parent="."] +modulate = Color(1, 1, 1, 0) +clip_children = 1 +anchors_preset = 7 +anchor_left = 0.5 +anchor_top = 1.0 +anchor_right = 0.5 +anchor_bottom = 1.0 +offset_left = 640.0 +offset_top = 940.0 +offset_right = 1280.0 +offset_bottom = 963.0 +grow_horizontal = 2 +grow_vertical = 0 +theme_override_font_sizes/font_size = 100 +text = "Too Crowded" +script = ExtResource("13_lkv81") + +[node name="TextureRect" type="TextureRect" parent="Notification"] +layout_mode = 0 +offset_right = 40.0 +offset_bottom = 40.0 +scale = Vector2(1, 3.12) +texture = SubResource("GradientTexture1D_ky2qs") + +[connection signal="timeout" from="Spawner/Timer" to="Spawner" method="spawn"] +[connection signal="timeout" from="Spawner2/Timer" to="Spawner2" method="spawn"] +[connection signal="timeout" from="Spawner3/Timer" to="Spawner3" method="spawn"] +[connection signal="visibility_changed" from="GameOver/Leaderboard" to="GameOver/Leaderboard" method="submit_score"] diff --git a/player.tscn b/player.tscn new file mode 100644 index 0000000..69f619f --- /dev/null +++ b/player.tscn @@ -0,0 +1,83 @@ +[gd_scene load_steps=10 format=3 uid="uid://cgcjicue76wsr"] + +[ext_resource type="Script" path="res://Player.gd" id="1_bu0dg"] +[ext_resource type="Texture2D" uid="uid://cyk2dqt7ipjg1" path="res://Arrow (1).png" id="2_cy2gs"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="3_w0118"] +[ext_resource type="Script" path="res://InfiniteGradient.gd" id="4_hwb8d"] +[ext_resource type="Script" path="res://PinnedLine.gd" id="5_as86f"] +[ext_resource type="Script" path="res://PinnedNode.gd" id="7_6wch2"] + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_xdd3j"] +gradient = ExtResource("3_w0118") + +[sub_resource type="Curve" id="Curve_7ru3n"] +_data = [Vector2(0, 0), 0.0, 0.0, 0, 0, Vector2(1, 1), 0.0, 0.0, 0, 0] +point_count = 2 + +[sub_resource type="Gradient" id="Gradient_l1fxo"] +offsets = PackedFloat32Array(0.756667, 1) +colors = PackedColorArray(0.48, 0.48, 1, 1, 0.51, 0.51, 1, 0) + +[node name="Player" type="RigidBody2D" groups=["destructible"]] +position = Vector2(-42, 74) +gravity_scale = 1.66533e-16 +linear_damp = 1.0 +script = ExtResource("1_bu0dg") + +[node name="TextureRect" type="TextureRect" parent="."] +clip_children = 1 +anchors_preset = 8 +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +offset_left = -256.0 +offset_top = -256.0 +offset_right = 256.0 +offset_bottom = 256.0 +grow_horizontal = 2 +grow_vertical = 2 +rotation = 1.5708 +scale = Vector2(0.1, 0.1) +pivot_offset = Vector2(256, 256) +texture = ExtResource("2_cy2gs") + +[node name="TextureRect" type="TextureRect" parent="TextureRect"] +layout_mode = 1 +anchors_preset = 13 +anchor_left = 0.5 +anchor_right = 0.5 +anchor_bottom = 1.0 +offset_left = -1024.0 +offset_right = 1024.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = SubResource("GradientTexture1D_xdd3j") +script = ExtResource("4_hwb8d") + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."] +visible = false +rotation = 1.5708 +scale = Vector2(0.1, 0.1) +polygon = PackedVector2Array(0, -155, 23, -147, 249, 89, 259, 113, 246, 142, 216, 155, 178, 148, 0, 52, -187, 150, -232, 148, -257, 116, -250, 89, -38, -136, -21, -147) + +[node name="RayCast2D" type="RayCast2D" parent="."] +visible = false +target_position = Vector2(5000, 2.08165e-12) + +[node name="Line2D" type="Line2D" parent="RayCast2D" node_paths=PackedStringArray("point_a", "point_b")] +z_index = -2 +points = PackedVector2Array(0, 0, 100, 2.08165e-12) +width = 100.0 +width_curve = SubResource("Curve_7ru3n") +gradient = SubResource("Gradient_l1fxo") +script = ExtResource("5_as86f") +point_a = NodePath("../..") +point_b = NodePath("../Marker2D") + +[node name="Marker2D" type="Marker2D" parent="RayCast2D"] +script = ExtResource("7_6wch2") + +[node name="Gun" type="Marker2D" parent="."] +visible = false +position = Vector2(53, 0) diff --git a/project.godot b/project.godot new file mode 100644 index 0000000..cf22180 --- /dev/null +++ b/project.godot @@ -0,0 +1,79 @@ +; Engine configuration file. +; It's best edited using the editor UI and not directly, +; since the parameters that go here are not all obvious. +; +; Format: +; [section] ; section goes between [] +; param=value ; assign values to parameters + +config_version=5 + +[application] + +config/name="Countdown" +run/main_scene="res://main.tscn" +config/features=PackedStringArray("4.2", "GL Compatibility") +config/icon="res://icon.svg" + +[display] + +window/size/viewport_width=1920 +window/size/viewport_height=1080 +window/stretch/mode="viewport" + +[editor] + +version_control/plugin_name="GitPlugin" +version_control/autoload_on_startup=true + +[input] + +up={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194320,"key_label":0,"unicode":0,"echo":false,"script":null) +, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":87,"key_label":0,"unicode":119,"echo":false,"script":null) +] +} +down={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194322,"key_label":0,"unicode":0,"echo":false,"script":null) +, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":83,"key_label":0,"unicode":115,"echo":false,"script":null) +] +} +left={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194319,"key_label":0,"unicode":0,"echo":false,"script":null) +, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":65,"key_label":0,"unicode":97,"echo":false,"script":null) +] +} +right={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194321,"key_label":0,"unicode":0,"echo":false,"script":null) +, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":68,"key_label":0,"unicode":100,"echo":false,"script":null) +] +} +restart={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":82,"key_label":0,"unicode":114,"echo":false,"script":null) +] +} +jump={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":32,"key_label":0,"unicode":32,"echo":false,"script":null) +] +} +quare={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":81,"key_label":0,"unicode":113,"echo":false,"script":null) +] +} +exagon={ +"deadzone": 0.5, +"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":69,"key_label":0,"unicode":101,"echo":false,"script":null) +] +} + +[rendering] + +renderer/rendering_method="gl_compatibility" +renderer/rendering_method.mobile="gl_compatibility" diff --git a/quare.gd b/quare.gd new file mode 100644 index 0000000..4ca6082 --- /dev/null +++ b/quare.gd @@ -0,0 +1,8 @@ +extends StaticBody2D + + +func destroy(): + var timer = Timer.new() + if not is_queued_for_deletion(): + $"../Player".aquire_quare() + queue_free() diff --git a/quare.png b/quare.png new file mode 100644 index 0000000..51bbf2f Binary files /dev/null and b/quare.png differ diff --git a/quare.png.import b/quare.png.import new file mode 100644 index 0000000..368de71 --- /dev/null +++ b/quare.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://regt4psf4pxw" +path="res://.godot/imported/quare.png-ab0056528a499e647ebe4838bd31ba15.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://quare.png" +dest_files=["res://.godot/imported/quare.png-ab0056528a499e647ebe4838bd31ba15.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/quare.tscn b/quare.tscn new file mode 100644 index 0000000..c94c36f --- /dev/null +++ b/quare.tscn @@ -0,0 +1,36 @@ +[gd_scene load_steps=8 format=3 uid="uid://b2tkfnqhx5xv"] + +[ext_resource type="Texture2D" uid="uid://regt4psf4pxw" path="res://quare.png" id="1_1dyuy"] +[ext_resource type="PhysicsMaterial" uid="uid://c5tm7od8mwjjb" path="res://elastic.tres" id="1_xwtag"] +[ext_resource type="Script" path="res://quare.gd" id="2_iatrf"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="2_xh8jo"] +[ext_resource type="Script" path="res://LockedRotation.gd" id="3_g8sg8"] + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_e1p40"] +size = Vector2(155, 155) + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_uwbqk"] +gradient = ExtResource("2_xh8jo") +width = 2048 + +[node name="Quare" type="StaticBody2D" groups=["destructible"]] +scale = Vector2(0.5, 0.5) +physics_material_override = ExtResource("1_xwtag") +script = ExtResource("2_iatrf") + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +shape = SubResource("RectangleShape2D_e1p40") +script = ExtResource("3_g8sg8") + +[node name="Sprite2D" type="Sprite2D" parent="."] +clip_children = 1 +scale = Vector2(0.3, 0.3) +texture = ExtResource("1_1dyuy") + +[node name="TextureRect" type="TextureRect" parent="Sprite2D"] +offset_left = -956.667 +offset_top = -266.667 +offset_right = 1091.33 +offset_bottom = -226.667 +scale = Vector2(1, 14.3333) +texture = SubResource("GradientTexture1D_uwbqk") diff --git a/riangle.tscn b/riangle.tscn new file mode 100644 index 0000000..c7ba96e --- /dev/null +++ b/riangle.tscn @@ -0,0 +1,57 @@ +[gd_scene load_steps=6 format=3 uid="uid://yu50iyftoyaj"] + +[ext_resource type="Texture2D" uid="uid://cartrcqnympin" path="res://Triangle.png" id="1_pjdof"] +[ext_resource type="Gradient" uid="uid://c41berdx2rqpw" path="res://gradient.tres" id="2_ic6q0"] +[ext_resource type="Script" path="res://Gun.gd" id="3_kffl0"] +[ext_resource type="PackedScene" uid="uid://c6ybtahxwpukd" path="res://bullet.tscn" id="4_tfncc"] + +[sub_resource type="GradientTexture1D" id="GradientTexture1D_u5oju"] +gradient = ExtResource("2_ic6q0") +width = 2048 + +[node name="Riangle" type="StaticBody2D" groups=["destructible"]] +scale = Vector2(0.25, 0.25) + +[node name="Sprite2D" type="Sprite2D" parent="."] +clip_children = 1 +rotation = 1.5708 +scale = Vector2(0.5, 0.5) +texture = ExtResource("1_pjdof") + +[node name="TextureRect" type="TextureRect" parent="Sprite2D"] +offset_left = -220.0 +offset_top = 265.0 +offset_right = 1828.0 +offset_bottom = 777.0 +rotation = -1.5708 +texture = SubResource("GradientTexture1D_u5oju") + +[node name="Gun2" type="Marker2D" parent="."] +position = Vector2(-224, 284) +rotation = 2.0944 +script = ExtResource("3_kffl0") +bullet = ExtResource("4_tfncc") + +[node name="Gun3" type="Marker2D" parent="."] +position = Vector2(-224, -284) +rotation = 4.18879 +script = ExtResource("3_kffl0") +bullet = ExtResource("4_tfncc") + +[node name="Gun" type="Marker2D" parent="."] +position = Vector2(272, 0) +script = ExtResource("3_kffl0") +bullet = ExtResource("4_tfncc") + +[node name="Timer" type="Timer" parent="."] +wait_time = 2.0 +autostart = true + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."] +position = Vector2(-8, 0) +polygon = PackedVector2Array(-80, -104, 100, 0, -80, 104) + +[connection signal="timeout" from="Timer" to="." method="queue_free"] +[connection signal="timeout" from="Timer" to="Gun2" method="shoot"] +[connection signal="timeout" from="Timer" to="Gun3" method="shoot"] +[connection signal="timeout" from="Timer" to="Gun" method="shoot"]