mirror of
https://github.com/Nokorpo/LibreAim.git
synced 2025-06-09 17:44:47 +09:00
Use Compatibility instead of Forward+
This commit is contained in:
parent
dd4389e63e
commit
0b7e8b8178
3 changed files with 8 additions and 5 deletions
|
@ -119,4 +119,6 @@ fullscreen={
|
|||
|
||||
[rendering]
|
||||
|
||||
renderer/rendering_method="gl_compatibility"
|
||||
renderer/rendering_method.mobile="gl_compatibility"
|
||||
environment/defaults/default_clear_color=Color(0.101961, 0.101961, 0.101961, 1)
|
||||
|
|
|
@ -3,7 +3,8 @@
|
|||
[ext_resource type="Script" path="res://scenes/game_world/bullet_hole.gd" id="1_a25ui"]
|
||||
[ext_resource type="Texture2D" uid="uid://cqospwtedgwrg" path="res://assets/images/hole.png" id="2_bi3vi"]
|
||||
|
||||
[node name="BulletHole" type="Decal"]
|
||||
size = Vector3(0.2, 0.2, 0.2)
|
||||
texture_albedo = ExtResource("2_bi3vi")
|
||||
[node name="BulletHole" type="Sprite3D"]
|
||||
transform = Transform3D(0.15, 0, 0, 0, 0.15, 0, 0, 0, 0.15, 0, 0, 0)
|
||||
modulate = Color(1, 1, 1, 0.784314)
|
||||
texture = ExtResource("2_bi3vi")
|
||||
script = ExtResource("1_a25ui")
|
||||
|
|
|
@ -93,8 +93,8 @@ func _shoot(damage: float) -> void:
|
|||
var bullet_hole_instance = bullet_hole.instantiate()
|
||||
|
||||
target.add_child(bullet_hole_instance)
|
||||
bullet_hole_instance.global_transform.origin = raycast.get_collision_point()
|
||||
bullet_hole_instance.look_at(position + Vector3.FORWARD, raycast.get_collision_normal())
|
||||
bullet_hole_instance.global_transform.origin = raycast.get_collision_point() + raycast.get_collision_normal() * 0.001
|
||||
bullet_hole_instance.look_at(bullet_hole_instance.global_position + raycast.get_collision_normal(), Vector3.FORWARD )
|
||||
|
||||
if target.is_in_group("Enemy"):
|
||||
target.health -= damage
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue