custom-material.tscn 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. [gd_scene load_steps=6 format=3 uid="uid://b4p2vn7bwm52a"]
  2. [ext_resource type="SpineSkeletonDataResource" path="res://assets/spineboy/spineboy-data-res.tres" id="1"]
  3. [sub_resource type="Shader" id="1"]
  4. code = "shader_type canvas_item;
  5. void fragment() {
  6. COLOR = texture(TEXTURE, UV);
  7. COLOR.r = 0.0;
  8. }"
  9. [sub_resource type="ShaderMaterial" id="2"]
  10. shader = SubResource( "1" )
  11. [sub_resource type="Shader" id="3"]
  12. code = "shader_type canvas_item;
  13. void fragment() {
  14. COLOR = texture(TEXTURE, UV);
  15. COLOR.b = 0.0;
  16. }"
  17. [sub_resource type="ShaderMaterial" id="4"]
  18. shader = SubResource( "3" )
  19. [node name="Node2D" type="Node2D"]
  20. [node name="SpineSprite" type="SpineSprite" parent="."]
  21. position = Vector2(501, 507)
  22. scale = Vector2(0.546374, 0.546373)
  23. skeleton_data_res = ExtResource( "1" )
  24. normal_material = SubResource( "2" )
  25. preview_animation = "-- Empty --"
  26. preview_frame = false
  27. preview_time = 0.0
  28. [node name="GunSlot" type="SpineSlotNode" parent="SpineSprite"]
  29. show_behind_parent = true
  30. position = Vector2(40.8753, -276.036)
  31. rotation = 0.837234
  32. slot_name = "gun"
  33. normal_material = SubResource( "4" )