Доработка. Теперь только для Godot4
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -18,3 +18,4 @@ mono_crash.*.json
|
|||||||
/build/
|
/build/
|
||||||
/html/
|
/html/
|
||||||
/commit.gd
|
/commit.gd
|
||||||
|
/.godot/
|
||||||
|
|||||||
33
DejaVuSans.ttf.import
Normal file
33
DejaVuSans.ttf.import
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="font_data_dynamic"
|
||||||
|
type="FontFile"
|
||||||
|
uid="uid://bxsp7iobid6r8"
|
||||||
|
path="res://.godot/imported/DejaVuSans.ttf-9b3237397afd1f73977bc4b24b10964d.fontdata"
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://DejaVuSans.ttf"
|
||||||
|
dest_files=["res://.godot/imported/DejaVuSans.ttf-9b3237397afd1f73977bc4b24b10964d.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={}
|
||||||
33
DejaVuSansCondensed.ttf.import
Normal file
33
DejaVuSansCondensed.ttf.import
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="font_data_dynamic"
|
||||||
|
type="FontFile"
|
||||||
|
uid="uid://bmpyjokeeeq8l"
|
||||||
|
path="res://.godot/imported/DejaVuSansCondensed.ttf-cf82d94147dd2c629554494e5fd511f4.fontdata"
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://DejaVuSansCondensed.ttf"
|
||||||
|
dest_files=["res://.godot/imported/DejaVuSansCondensed.ttf-cf82d94147dd2c629554494e5fd511f4.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={}
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
[gd_scene load_steps=2 format=2]
|
[gd_scene load_steps=2 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://nine-patch.png" type="Texture" id=1]
|
[ext_resource path="res://nine-patch.png" type="Texture2D" id=1]
|
||||||
|
|
||||||
[node name="NinePatchRect" type="NinePatchRect"]
|
[node name="NinePatchRect" type="NinePatchRect"]
|
||||||
margin_right = 42.0
|
offset_right = 42.0
|
||||||
margin_bottom = 33.0
|
offset_bottom = 33.0
|
||||||
texture = ExtResource( 1 )
|
texture = ExtResource( 1 )
|
||||||
draw_center = false
|
draw_center = false
|
||||||
patch_margin_left = 8
|
patch_margin_left = 8
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
extends Node2D
|
extends Node2D
|
||||||
|
|
||||||
export (String, FILE) var MENU_SCENE_FILE = 'res://меню.tscn'
|
const MENU_SCENE_FILE: String = 'res://меню.tscn'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Адрес имитатора
|
# Адрес имитатора
|
||||||
const MAIN_ADDR = [ '10.1.1.5', 50005 ]
|
const MAIN_ADDR = [ 'localhost', 50005 ]
|
||||||
const DST_ADDR = [ '10.1.1.79', 50079 ]
|
const DST_ADDR = [ 'localhost', 50079 ]
|
||||||
|
|
||||||
|
|
||||||
const TABLE_ROW_HIGHT = 34 # Высота строки таблицы в пикселях
|
const TABLE_ROW_HIGHT = 34 # Высота строки таблицы в пикселях
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/edit-add-0.png-caa21a9bbc05466cba52fa8d3bc8c950.stex"
|
uid="uid://cex4jiu1pcj3x"
|
||||||
|
path="res://.godot/imported/edit-add-0.png-caa21a9bbc05466cba52fa8d3bc8c950.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://edit-add-0.png"
|
source_file="res://edit-add-0.png"
|
||||||
dest_files=[ "res://.import/edit-add-0.png-caa21a9bbc05466cba52fa8d3bc8c950.stex" ]
|
dest_files=["res://.godot/imported/edit-add-0.png-caa21a9bbc05466cba52fa8d3bc8c950.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/edit-add-1.png-8bbd18fd95c5b5bd62e9c26d8f22f02b.stex"
|
uid="uid://cx746np1wexnd"
|
||||||
|
path="res://.godot/imported/edit-add-1.png-8bbd18fd95c5b5bd62e9c26d8f22f02b.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://edit-add-1.png"
|
source_file="res://edit-add-1.png"
|
||||||
dest_files=[ "res://.import/edit-add-1.png-8bbd18fd95c5b5bd62e9c26d8f22f02b.stex" ]
|
dest_files=["res://.godot/imported/edit-add-1.png-8bbd18fd95c5b5bd62e9c26d8f22f02b.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex"
|
uid="uid://bwqivxm0vit47"
|
||||||
|
path="res://.godot/imported/icon.png-487276ed1e3a0c39cad0279d744ee560.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://icon.png"
|
source_file="res://icon.png"
|
||||||
dest_files=[ "res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex" ]
|
dest_files=["res://.godot/imported/icon.png-487276ed1e3a0c39cad0279d744ee560.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[gd_resource type="DynamicFont" load_steps=2 format=2]
|
[gd_resource type="FontFile" load_steps=2 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://DejaVuSansCondensed.ttf" type="DynamicFontData" id=1]
|
[ext_resource path="res://DejaVuSansCondensed.ttf" type="FontFile" id=1]
|
||||||
|
|
||||||
[resource]
|
[resource]
|
||||||
size = 20
|
size = 20
|
||||||
|
|||||||
16
main.gd
16
main.gd
@@ -1,22 +1,22 @@
|
|||||||
extends Node2D
|
extends Node2D
|
||||||
|
|
||||||
var sock = PacketPeerUDP.new()
|
var sock = PacketPeerUDP.new()
|
||||||
onready var header_threads = get_node('tabs/threats/header_t')
|
@onready var header_threads = get_node('tabs/threats/header_t')
|
||||||
onready var table_threads = get_node('tabs/threats/table_t')
|
@onready var table_threads = get_node('tabs/threats/table_t')
|
||||||
onready var btn_add_threads = get_node('tabs/threats/btn_add')
|
@onready var btn_add_threads = get_node('tabs/threats/btn_add')
|
||||||
onready var btn_del_threads = get_node('tabs/threats/btn_del')
|
@onready var btn_del_threads = get_node('tabs/threats/btn_del')
|
||||||
|
|
||||||
onready var header_pomehi = get_node('tabs/pomehi/header_p')
|
@onready var header_pomehi = get_node('tabs/pomehi/header_p')
|
||||||
onready var table_pomehi = get_node('tabs/pomehi/table_p')
|
@onready var table_pomehi = get_node('tabs/pomehi/table_p')
|
||||||
|
|
||||||
# Called when the node enters the scene tree for the first time.
|
# Called when the node enters the scene tree for the first time.
|
||||||
func _ready():
|
func _ready():
|
||||||
sock.listen(Consts.MAIN_ADDR[1], Consts.MAIN_ADDR[0])
|
sock.bind(Consts.MAIN_ADDR[1], Consts.MAIN_ADDR[0])
|
||||||
sock.set_dest_address(Consts.DST_ADDR[0], Consts.DST_ADDR[1])
|
sock.set_dest_address(Consts.DST_ADDR[0], Consts.DST_ADDR[1])
|
||||||
Threats.init_treats(header_threads, table_threads, btn_add_threads, btn_del_threads)
|
Threats.init_treats(header_threads, table_threads, btn_add_threads, btn_del_threads)
|
||||||
Pomehi.init_pomehi(header_pomehi, table_pomehi)
|
Pomehi.init_pomehi(header_pomehi, table_pomehi)
|
||||||
var timer = Timer.new()
|
var timer = Timer.new()
|
||||||
timer.connect('timeout',self,'on_timeout',[])
|
timer.connect('timeout', Callable(self, 'on_timeout').bind())
|
||||||
add_child(timer) #to process
|
add_child(timer) #to process
|
||||||
timer.start(1) #to start
|
timer.start(1) #to start
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
[gd_resource type="Environment" load_steps=2 format=2]
|
[gd_resource type="Environment" load_steps=2 format=3 uid="uid://sjt0ts5hhqrl"]
|
||||||
|
|
||||||
[sub_resource type="ProceduralSky" id=1]
|
[sub_resource type="Sky" id="1"]
|
||||||
|
|
||||||
[resource]
|
[resource]
|
||||||
background_mode = 2
|
background_mode = 2
|
||||||
background_sky = SubResource( 1 )
|
sky = SubResource("1")
|
||||||
|
|||||||
87
main.tscn
87
main.tscn
@@ -1,69 +1,66 @@
|
|||||||
[gd_scene load_steps=5 format=2]
|
[gd_scene load_steps=5 format=3 uid="uid://87gtvqd7bbje"]
|
||||||
|
|
||||||
[ext_resource path="res://table.gd" type="Script" id=1]
|
[ext_resource type="Script" path="res://main.gd" id="1_kt06w"]
|
||||||
[ext_resource path="res://main.gd" type="Script" id=2]
|
[ext_resource type="Script" path="res://table.gd" id="2_k7rc6"]
|
||||||
[ext_resource path="res://edit-add-0.png" type="Texture" id=3]
|
[ext_resource type="Texture2D" uid="uid://cex4jiu1pcj3x" path="res://edit-add-0.png" id="3_pruca"]
|
||||||
[ext_resource path="res://edit-add-1.png" type="Texture" id=4]
|
[ext_resource type="Texture2D" uid="uid://cx746np1wexnd" path="res://edit-add-1.png" id="4_3d2wd"]
|
||||||
|
|
||||||
[node name="main" type="Node2D"]
|
[node name="main" type="Node2D"]
|
||||||
script = ExtResource( 2 )
|
script = ExtResource("1_kt06w")
|
||||||
|
|
||||||
[node name="tabs" type="TabContainer" parent="."]
|
[node name="tabs" type="TabContainer" parent="."]
|
||||||
margin_right = 1594.0
|
offset_right = 1594.0
|
||||||
margin_bottom = 897.0
|
offset_bottom = 897.0
|
||||||
tab_align = 0
|
|
||||||
|
|
||||||
[node name="threats" type="Panel" parent="tabs"]
|
[node name="threats" type="Panel" parent="tabs"]
|
||||||
anchor_right = 1.0
|
layout_mode = 2
|
||||||
anchor_bottom = 1.0
|
|
||||||
margin_left = 4.0
|
|
||||||
margin_top = 42.0
|
|
||||||
margin_right = -4.0
|
|
||||||
margin_bottom = -4.0
|
|
||||||
|
|
||||||
[node name="table_t" type="GridContainer" parent="tabs/threats"]
|
[node name="table_t" type="GridContainer" parent="tabs/threats"]
|
||||||
|
layout_mode = 0
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
anchor_bottom = 1.0
|
anchor_bottom = 1.0
|
||||||
margin_top = 100.0
|
offset_top = 100.0
|
||||||
margin_right = 1.0
|
offset_right = 1.0
|
||||||
margin_bottom = 10.0
|
offset_bottom = 10.0
|
||||||
script = ExtResource( 1 )
|
script = ExtResource("2_k7rc6")
|
||||||
|
|
||||||
[node name="header_t" type="GridContainer" parent="tabs/threats"]
|
[node name="header_t" type="GridContainer" parent="tabs/threats"]
|
||||||
margin_top = 57.0
|
layout_mode = 0
|
||||||
margin_right = 1584.0
|
offset_top = 57.0
|
||||||
margin_bottom = 96.0
|
offset_right = 1584.0
|
||||||
script = ExtResource( 1 )
|
offset_bottom = 96.0
|
||||||
|
script = ExtResource("2_k7rc6")
|
||||||
|
|
||||||
[node name="btn_add" type="TextureButton" parent="tabs/threats"]
|
[node name="btn_add" type="TextureButton" parent="tabs/threats"]
|
||||||
margin_left = 1533.0
|
layout_mode = 0
|
||||||
margin_top = -2.0
|
offset_left = 1533.0
|
||||||
margin_right = 1581.0
|
offset_top = -2.0
|
||||||
margin_bottom = 46.0
|
offset_right = 1581.0
|
||||||
texture_normal = ExtResource( 3 )
|
offset_bottom = 46.0
|
||||||
texture_pressed = ExtResource( 4 )
|
texture_normal = ExtResource("3_pruca")
|
||||||
|
texture_pressed = ExtResource("4_3d2wd")
|
||||||
|
|
||||||
[node name="btn_del" type="TextureButton" parent="tabs/threats"]
|
[node name="btn_del" type="TextureButton" parent="tabs/threats"]
|
||||||
margin_left = 1487.0
|
layout_mode = 0
|
||||||
margin_top = 3.0
|
offset_left = 1487.0
|
||||||
margin_right = 1527.0
|
offset_top = 3.0
|
||||||
margin_bottom = 43.0
|
offset_right = 1527.0
|
||||||
|
offset_bottom = 43.0
|
||||||
|
|
||||||
[node name="pomehi" type="Panel" parent="tabs"]
|
[node name="pomehi" type="Panel" parent="tabs"]
|
||||||
visible = false
|
visible = false
|
||||||
margin_left = 4.0
|
layout_mode = 2
|
||||||
margin_top = 42.0
|
|
||||||
margin_right = 1590.0
|
|
||||||
margin_bottom = 893.0
|
|
||||||
|
|
||||||
[node name="table_p" type="GridContainer" parent="tabs/pomehi"]
|
[node name="table_p" type="GridContainer" parent="tabs/pomehi"]
|
||||||
margin_top = 100.0
|
layout_mode = 0
|
||||||
margin_right = 1587.0
|
offset_top = 100.0
|
||||||
margin_bottom = 861.0
|
offset_right = 1587.0
|
||||||
script = ExtResource( 1 )
|
offset_bottom = 861.0
|
||||||
|
script = ExtResource("2_k7rc6")
|
||||||
|
|
||||||
[node name="header_p" type="GridContainer" parent="tabs/pomehi"]
|
[node name="header_p" type="GridContainer" parent="tabs/pomehi"]
|
||||||
margin_top = 57.0
|
layout_mode = 0
|
||||||
margin_right = 32.0
|
offset_top = 57.0
|
||||||
margin_bottom = 96.0
|
offset_right = 32.0
|
||||||
script = ExtResource( 1 )
|
offset_bottom = 96.0
|
||||||
|
script = ExtResource("2_k7rc6")
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/nine-patch.png-57e7212ba67c39e7fc9011f4afa7baae.stex"
|
uid="uid://bkjlwivmtq1rp"
|
||||||
|
path="res://.godot/imported/nine-patch.png-57e7212ba67c39e7fc9011f4afa7baae.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://nine-patch.png"
|
source_file="res://nine-patch.png"
|
||||||
dest_files=[ "res://.import/nine-patch.png-57e7212ba67c39e7fc9011f4afa7baae.stex" ]
|
dest_files=["res://.godot/imported/nine-patch.png-57e7212ba67c39e7fc9011f4afa7baae.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
35
pomehi.gd
35
pomehi.gd
@@ -14,9 +14,9 @@ const TableCellType6 = preload('res://кнопка-5.tscn')
|
|||||||
# Индекс колонки: 0 1 2 3 4 5 6
|
# Индекс колонки: 0 1 2 3 4 5 6
|
||||||
const TABLE_HEADERS = [ 'Индекс', 'Состояние', 'Помеха', 'Мощность', 'Кур. уг.', 'Частота', 'Ш. диап.']
|
const TABLE_HEADERS = [ 'Индекс', 'Состояние', 'Помеха', 'Мощность', 'Кур. уг.', 'Частота', 'Ш. диап.']
|
||||||
const TABLE_HEADER_TYPES = [ TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4]
|
const TABLE_HEADER_TYPES = [ TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4]
|
||||||
const TABLE_HEADER_ALIGNMENTS = [ HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER]
|
const TABLE_HEADER_ALIGNMENTS = [ HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER]
|
||||||
const TABLE_ROW_TYPES = [ TableCellType1, TableCellType6, TableCellType1, TableCellType1, TableCellType1, TableCellType1, TableCellType1]
|
const TABLE_ROW_TYPES = [ TableCellType1, TableCellType6, TableCellType1, TableCellType1, TableCellType1, TableCellType1, TableCellType1]
|
||||||
const TABLE_ROW_ALIGNMENTS = [ HALIGN_CENTER, HALIGN_LEFT, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER]
|
const TABLE_ROW_ALIGNMENTS = [ HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER]
|
||||||
const TABLE_COLUMN_SIZES = [ 82, 120, 82, 100, 82, 90, 150]
|
const TABLE_COLUMN_SIZES = [ 82, 120, 82, 100, 82, 90, 150]
|
||||||
|
|
||||||
const COLUMN_ISPP = 0 # Индекс сейанса постановки помехи
|
const COLUMN_ISPP = 0 # Индекс сейанса постановки помехи
|
||||||
@@ -59,23 +59,22 @@ class Pomeha:
|
|||||||
var width : String
|
var width : String
|
||||||
|
|
||||||
func _init(args : Array):
|
func _init(args : Array):
|
||||||
ispp = String(args[0])
|
ispp = '%s' % args[0]
|
||||||
krp = String(args[1])
|
krp = '%s' % args[1]
|
||||||
powp = String(args[2])
|
powp = '%s' % args[2]
|
||||||
kni = String(args[3])
|
kni = '%s' % args[3]
|
||||||
freq = String(args[4])
|
freq = '%s' % args[4]
|
||||||
width = String(args[5])
|
width = '%s' % args[5]
|
||||||
|
|
||||||
|
|
||||||
func update_rows():
|
func update_rows():
|
||||||
var new_rows: Array = []
|
var new_rows: Array = []
|
||||||
new_rows.append(String(ispp))
|
new_rows.append('%s' % ispp)
|
||||||
new_rows.append(String(svk))
|
new_rows.append('%s' % svk)
|
||||||
new_rows.append(String(krp))
|
new_rows.append('%s' % krp)
|
||||||
new_rows.append(String(powp))
|
new_rows.append('%s' % powp)
|
||||||
new_rows.append(String(kni))
|
new_rows.append('%s' % kni)
|
||||||
new_rows.append(String(freq))
|
new_rows.append('%s' % freq)
|
||||||
new_rows.append(String(width))
|
new_rows.append('%s' % width)
|
||||||
return new_rows
|
return new_rows
|
||||||
|
|
||||||
|
|
||||||
@@ -106,13 +105,13 @@ func init_pomehi(header, table): # Инициализация вкладк
|
|||||||
init_table(header, TABLE_COLUMN_SIZES)
|
init_table(header, TABLE_COLUMN_SIZES)
|
||||||
init_table(table, TABLE_COLUMN_SIZES)
|
init_table(table, TABLE_COLUMN_SIZES)
|
||||||
table.align_to_left_bottom(header, Vector2(0, 2))
|
table.align_to_left_bottom(header, Vector2(0, 2))
|
||||||
table.connect('row_pressed', self, 'on_row_pressed', [table])
|
table.connect('row_pressed', Callable(self, 'on_row_pressed').bind(table))
|
||||||
table.set_callbacks(self, 'item_selected', 'on_item_selected', COLUMN_OPT_BTN, [table])
|
table.set_callbacks(self, 'item_selected', 'on_item_selected', COLUMN_OPT_BTN, [table])
|
||||||
|
|
||||||
|
|
||||||
func on_btn_add(table):
|
func on_btn_add(table):
|
||||||
var pomeha : = Pomeha.new([1,2,3,4,5,6])
|
var pomeha : = Pomeha.new([1,2,3,4,5,6])
|
||||||
pomehi[String(1)] = pomeha
|
pomehi['%d' % 1] = pomeha
|
||||||
var row = pomeha.update_rows()
|
var row = pomeha.update_rows()
|
||||||
table.add_row(TABLE_ROW_TYPES)
|
table.add_row(TABLE_ROW_TYPES)
|
||||||
table.set_row_text(table.get_rows_count()-1, row)
|
table.set_row_text(table.get_rows_count()-1, row)
|
||||||
|
|||||||
@@ -6,12 +6,13 @@
|
|||||||
; [section] ; section goes between []
|
; [section] ; section goes between []
|
||||||
; param=value ; assign values to parameters
|
; param=value ; assign values to parameters
|
||||||
|
|
||||||
config_version=4
|
config_version=5
|
||||||
|
|
||||||
[application]
|
[application]
|
||||||
|
|
||||||
config/name="Imi Skysens"
|
config/name="Imi Skysens"
|
||||||
run/main_scene="res://main.tscn"
|
run/main_scene="res://main.tscn"
|
||||||
|
config/features=PackedStringArray("4.1")
|
||||||
config/icon="res://icon.png"
|
config/icon="res://icon.png"
|
||||||
|
|
||||||
[autoload]
|
[autoload]
|
||||||
@@ -24,15 +25,14 @@ Tools="*res://tools.gd"
|
|||||||
|
|
||||||
[display]
|
[display]
|
||||||
|
|
||||||
window/size/width=1600
|
window/size/viewport_width=1600
|
||||||
window/size/height=900
|
window/size/viewport_height=900
|
||||||
window/stretch/mode="2d"
|
window/stretch/mode="2d"
|
||||||
window/stretch/aspect="keep"
|
|
||||||
|
|
||||||
[gui]
|
[gui]
|
||||||
|
|
||||||
common/drop_mouse_on_gui_input_disabled=true
|
|
||||||
theme/custom_font="res://main-font.tres"
|
theme/custom_font="res://main-font.tres"
|
||||||
|
common/drop_mouse_on_gui_input_disabled=true
|
||||||
|
|
||||||
[physics]
|
[physics]
|
||||||
|
|
||||||
@@ -40,4 +40,4 @@ common/enable_pause_aware_picking=true
|
|||||||
|
|
||||||
[rendering]
|
[rendering]
|
||||||
|
|
||||||
environment/default_environment="res://main.tres"
|
environment/defaults/default_environment="res://main.tres"
|
||||||
|
|||||||
100
table.gd
100
table.gd
@@ -1,10 +1,10 @@
|
|||||||
tool
|
@tool
|
||||||
extends GridContainer
|
extends GridContainer
|
||||||
|
|
||||||
export (Color) var _selector_color = Color(1.0, 1.0, 1.0, 1.0)
|
@export var _selector_color: Color = Color(1.0, 1.0, 1.0, 1.0)
|
||||||
export (int, 1, 256) var columns_count = 1 setget _set_columns_count
|
@export var columns_count: int = 1: set = _set_columns_count
|
||||||
export (int, 1, 256) var rows_count = 1 setget _set_rows_count
|
@export var rows_count: int = 1: set = _set_rows_count
|
||||||
export (String, FILE) var node_type_file = 'res://ячейка-1.tscn'
|
@export var node_type_file: String = 'res://ячейка-1.tscn'
|
||||||
const Selector = preload('res://Selector.tscn')
|
const Selector = preload('res://Selector.tscn')
|
||||||
const INDEX_FORMAT = '%02d_%02d'
|
const INDEX_FORMAT = '%02d_%02d'
|
||||||
const NODE_PREFIX = 'NODE_'
|
const NODE_PREFIX = 'NODE_'
|
||||||
@@ -18,20 +18,20 @@ const CONNECTED_KEY_FORMAT = CONN_PREFIX + INDEX_FORMAT
|
|||||||
const ROW_SELECTOR_KEY_FORMAT = SLCT_PREFIX + INDEX_FORMAT
|
const ROW_SELECTOR_KEY_FORMAT = SLCT_PREFIX + INDEX_FORMAT
|
||||||
|
|
||||||
var nodes: = {}
|
var nodes: = {}
|
||||||
var selector_color_proc: FuncRef
|
var selector_color_proc: Callable
|
||||||
var selector_size_proc: FuncRef
|
var selector_size_proc: Callable
|
||||||
signal row_pressed(i_row) # Вызывается при нажатии кнопкой мыши на строку
|
signal row_pressed(i_row) # Вызывается при нажатии кнопкой мыши на строку
|
||||||
const MAX_INDEX = 99 # Максимальное значение индекса для колонки и строки. Связано с форматом ключа
|
const MAX_INDEX = 99 # Максимальное значение индекса для колонки и строки. Связано с форматом ключа
|
||||||
|
|
||||||
|
|
||||||
func align_to_left_bottom(header, gap: = Vector2(0, 0)):
|
func align_to_left_bottom(header, gap: = Vector2(0, 0)):
|
||||||
""" Выравнивает по нижнему левому углу. Используется для выравнивания по заголовку """
|
""" Выравнивает по нижнему левому углу. Используется для выравнивания по заголовку """
|
||||||
rect_position.x = header.rect_position.x + gap.x
|
position.x = header.position.x + gap.x
|
||||||
rect_position.y = header.rect_position.y + header.rect_size.y + gap.y
|
position.y = header.position.y + header.size.y + gap.y
|
||||||
|
|
||||||
|
|
||||||
func _assert_meta(i_col: int, i_row: int, pname: String, node):
|
func _assert_meta(i_col: int, i_row: int, pname: String, node):
|
||||||
assert(node.has_meta(pname), 'ошибка: нет мета-свойства \"%s\" у ячейки (%s): колонка:%d ряд:%d' % [pname, typeof(node), i_col, i_row])
|
assert(node.has_meta(pname)) #,'ошибка: нет мета-свойства \"%s\" у ячейки (%s): колонка:%d ряд:%d' % [pname, typeof(node), i_col, i_row])
|
||||||
|
|
||||||
|
|
||||||
func _set_columns_count(cc: int):
|
func _set_columns_count(cc: int):
|
||||||
@@ -69,13 +69,13 @@ func get_node_property(i_col: int, i_row: int, pname: String):
|
|||||||
|
|
||||||
func get_node_key(format: String, i_col: int, i_row: int) -> String:
|
func get_node_key(format: String, i_col: int, i_row: int) -> String:
|
||||||
var key: String = format % [i_row, i_col]
|
var key: String = format % [i_row, i_col]
|
||||||
assert(nodes.has(key), 'ошибка: нет такой ячейки: колонка:%d ряд:%d' % [i_col, i_row])
|
assert(nodes.has(key)) #,'ошибка: нет такой ячейки: колонка:%d ряд:%d' % [i_col, i_row])
|
||||||
return key
|
return key
|
||||||
|
|
||||||
|
|
||||||
func get_key_indexes(key: String) -> Array:
|
func get_key_indexes(key: String) -> Array:
|
||||||
var tokens: = key.split('_')
|
var tokens: = key.split('_')
|
||||||
assert(tokens.size() == 3, 'ошибка: неверный ключ: \"%s\"' % key)
|
assert(tokens.size() == 3) #,'ошибка: неверный ключ: \"%s\"' % key)
|
||||||
return [int(tokens[2]), int(tokens[1])]
|
return [int(tokens[2]), int(tokens[1])]
|
||||||
|
|
||||||
|
|
||||||
@@ -94,25 +94,25 @@ func _input(event) -> void:
|
|||||||
if event is InputEventMouseButton:
|
if event is InputEventMouseButton:
|
||||||
if not event.pressed:
|
if not event.pressed:
|
||||||
return
|
return
|
||||||
if event.position.x < rect_position.x:
|
if event.position.x < position.x:
|
||||||
emit_signal('focus_exited')
|
emit_signal('focus_exited')
|
||||||
return
|
return
|
||||||
if event.position.x > (rect_position.x + rect_size.x):
|
if event.position.x > (position.x + size.x):
|
||||||
emit_signal('focus_exited')
|
emit_signal('focus_exited')
|
||||||
return
|
return
|
||||||
if event.position.y < rect_position.y:
|
if event.position.y < position.y:
|
||||||
emit_signal('focus_exited')
|
emit_signal('focus_exited')
|
||||||
return
|
return
|
||||||
if event.position.y > (rect_position.y + rect_size.y):
|
if event.position.y > (position.y + size.y):
|
||||||
emit_signal('focus_exited')
|
emit_signal('focus_exited')
|
||||||
return
|
return
|
||||||
var rows_count: = get_rows_count()
|
var rows_count: = get_rows_count()
|
||||||
var parent = get_parent()
|
var parent = get_parent()
|
||||||
var y0 = parent.rect_position.y
|
var y0 = parent.position.y
|
||||||
for i_row in rows_count:
|
for i_row in rows_count:
|
||||||
var rect = [0, 0, 0, 0]
|
var rect = [0, 0, 0, 0]
|
||||||
get_node_rect(0, i_row, rect)
|
get_node_rect(0, i_row, rect)
|
||||||
var y = rect[1] + rect_position.y + y0
|
var y = rect[1] + position.y + y0
|
||||||
if event.position.y < y:
|
if event.position.y < y:
|
||||||
continue
|
continue
|
||||||
if event.position.y > (y + rect[3]):
|
if event.position.y > (y + rect[3]):
|
||||||
@@ -122,13 +122,9 @@ func _input(event) -> void:
|
|||||||
|
|
||||||
|
|
||||||
func _init() -> void:
|
func _init() -> void:
|
||||||
selector_color_proc = FuncRef.new()
|
selector_color_proc = Callable(self, 'default_selector_color_proc')
|
||||||
selector_color_proc.set_instance(self)
|
|
||||||
selector_color_proc.function = 'default_selector_color_proc'
|
|
||||||
assert(selector_color_proc.is_valid())
|
assert(selector_color_proc.is_valid())
|
||||||
selector_size_proc = FuncRef.new()
|
selector_size_proc = Callable(self, 'default_selector_size_proc')
|
||||||
selector_size_proc.set_instance(self)
|
|
||||||
selector_size_proc.function = 'default_selector_size_proc'
|
|
||||||
assert(selector_size_proc.is_valid())
|
assert(selector_size_proc.is_valid())
|
||||||
|
|
||||||
|
|
||||||
@@ -137,22 +133,20 @@ func default_selector_color_proc(i_row: int):
|
|||||||
|
|
||||||
|
|
||||||
func set_selector_color_proc(instance: Object, function: String) -> void:
|
func set_selector_color_proc(instance: Object, function: String) -> void:
|
||||||
selector_color_proc.set_instance(instance)
|
selector_color_proc = Callable(instance, function)
|
||||||
selector_color_proc.function = function
|
|
||||||
assert(selector_color_proc.is_valid())
|
assert(selector_color_proc.is_valid())
|
||||||
|
|
||||||
|
|
||||||
func set_selector_size_proc(instance: Object, function: String) -> void:
|
func set_selector_size_proc(instance: Object, function: String) -> void:
|
||||||
selector_size_proc.set_instance(instance)
|
selector_size_proc = Callable(instance, function)
|
||||||
selector_size_proc.function = function
|
|
||||||
assert(selector_size_proc.is_valid())
|
assert(selector_size_proc.is_valid())
|
||||||
|
|
||||||
|
|
||||||
func default_selector_size_proc(i_row: int, rect: Array) -> void:
|
func default_selector_size_proc(i_row: int, rect: Array) -> void:
|
||||||
get_node_rect(0, i_row, rect)
|
get_node_rect(0, i_row, rect)
|
||||||
rect[0] = rect[0] + rect_position.x - 1
|
rect[0] = rect[0] + position.x - 1
|
||||||
rect[1] = rect[1] + rect_position.y - 4
|
rect[1] = rect[1] + position.y - 4
|
||||||
rect[2] = rect_size.x + 2
|
rect[2] = size.x + 2
|
||||||
rect[3] = rect[3] + 8
|
rect[3] = rect[3] + 8
|
||||||
|
|
||||||
|
|
||||||
@@ -171,14 +165,14 @@ func set_row_selected(i_row: int, selected: bool = true) -> void:
|
|||||||
selector.queue_free()
|
selector.queue_free()
|
||||||
nodes.erase(key)
|
nodes.erase(key)
|
||||||
elif (not nodes.has(key)) and selected:
|
elif (not nodes.has(key)) and selected:
|
||||||
var selector = Selector.instance()
|
var selector = Selector.instantiate()
|
||||||
var rect: = [0, 0, 0, 0]
|
var rect: = [0, 0, 0, 0]
|
||||||
selector_size_proc.call_func(i_row, rect)
|
selector_size_proc.call(i_row, rect)
|
||||||
selector.rect_position.x = rect[0]
|
selector.position.x = rect[0]
|
||||||
selector.rect_position.y = rect[1]
|
selector.position.y = rect[1]
|
||||||
selector.rect_size.x = rect[2]
|
selector.size.x = rect[2]
|
||||||
selector.rect_size.y = rect[3]
|
selector.size.y = rect[3]
|
||||||
selector.modulate = selector_color_proc.call_func(i_row)
|
selector.modulate = selector_color_proc.call(i_row)
|
||||||
nodes[key] = selector
|
nodes[key] = selector
|
||||||
parent.add_child(selector)
|
parent.add_child(selector)
|
||||||
|
|
||||||
@@ -218,7 +212,7 @@ func add_row(row_types: Array) -> void:
|
|||||||
var rows_count: int = get_rows_count()
|
var rows_count: int = get_rows_count()
|
||||||
assert(rows_count < MAX_INDEX, 'ошибка: слишком много рядов, больше %d' % (MAX_INDEX + 1))
|
assert(rows_count < MAX_INDEX, 'ошибка: слишком много рядов, больше %d' % (MAX_INDEX + 1))
|
||||||
for i_col in columns:
|
for i_col in columns:
|
||||||
var node = row_types[i_col].instance()
|
var node = row_types[i_col].instantiate()
|
||||||
var key: String = NODE_KEY_FORMAT % [rows_count, i_col]
|
var key: String = NODE_KEY_FORMAT % [rows_count, i_col]
|
||||||
node.name = key
|
node.name = key
|
||||||
add_child(node)
|
add_child(node)
|
||||||
@@ -253,14 +247,14 @@ func remove_row(i_row: int):
|
|||||||
var conn = nodes[conn_key]
|
var conn = nodes[conn_key]
|
||||||
var callback = conn[0]
|
var callback = conn[0]
|
||||||
var dest_node = conn[1]
|
var dest_node = conn[1]
|
||||||
node.disconnect('pressed', dest_node, callback)
|
node.disconnect('pressed', Callable(dest_node, callback))
|
||||||
nodes.erase(conn_key)
|
nodes.erase(conn_key)
|
||||||
|
|
||||||
|
|
||||||
func rehash(swaps: Array):
|
func rehash(swaps: Array):
|
||||||
""" Переназначает ключи в соответствии с размерами таблицы.
|
""" Переназначает ключи в соответствии с размерами таблицы.
|
||||||
После вызова swaps содержит массив пар [<прежний ключ>, <текущий ключ>] """
|
После вызова swaps содержит массив пар [<прежний ключ>, <текущий ключ>] """
|
||||||
assert(not swaps.size(), 'ошибка: swaps не пустой')
|
assert(not swaps.size()) #,'ошибка: swaps не пустой')
|
||||||
var nodes_copy = {}
|
var nodes_copy = {}
|
||||||
var i_col = 0
|
var i_col = 0
|
||||||
var i_row = 0
|
var i_row = 0
|
||||||
@@ -312,7 +306,7 @@ func set_callbacks(dest_node: Node, event_name: String, callback: String, clmns:
|
|||||||
var rows_count = get_rows_count()
|
var rows_count = get_rows_count()
|
||||||
for i_row in rows_count:
|
for i_row in rows_count:
|
||||||
for i_col in clmns:
|
for i_col in clmns:
|
||||||
assert(i_col >= 0 and i_col < columns, 'ошибка: нет колонки %d' % i_col)
|
assert(i_col >= 0 and i_col < columns) #,'ошибка: нет колонки %d' % i_col)
|
||||||
var node_key: String = NODE_KEY_FORMAT % [i_row, i_col]
|
var node_key: String = NODE_KEY_FORMAT % [i_row, i_col]
|
||||||
var conn_key: String = CONNECTED_KEY_FORMAT % [i_row, i_col]
|
var conn_key: String = CONNECTED_KEY_FORMAT % [i_row, i_col]
|
||||||
var node = nodes[node_key]
|
var node = nodes[node_key]
|
||||||
@@ -320,8 +314,8 @@ func set_callbacks(dest_node: Node, event_name: String, callback: String, clmns:
|
|||||||
var conn = nodes[conn_key]
|
var conn = nodes[conn_key]
|
||||||
var prev_callback = conn[0]
|
var prev_callback = conn[0]
|
||||||
var prev_dest_node = conn[1]
|
var prev_dest_node = conn[1]
|
||||||
node.disconnect(event_name, prev_dest_node, prev_callback)
|
node.disconnect(event_name, Callable(prev_dest_node, prev_callback))
|
||||||
assert (OK == node.connect(event_name, dest_node, callback, [node] + user_data))
|
assert (OK == node.connect(event_name, Callable(dest_node, callback).bind([node] + user_data)))
|
||||||
nodes[conn_key] = [callback, dest_node]
|
nodes[conn_key] = [callback, dest_node]
|
||||||
|
|
||||||
|
|
||||||
@@ -337,8 +331,8 @@ func set_nodes_min_size(i_row: int, sizes: Array) -> void:
|
|||||||
for i_col in columns:
|
for i_col in columns:
|
||||||
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
||||||
var node = nodes[key]
|
var node = nodes[key]
|
||||||
node.rect_min_size.x = sizes[i_col]
|
node.custom_minimum_size.x = sizes[i_col]
|
||||||
node.rect_size.x = sizes[i_col]
|
node.size.x = sizes[i_col]
|
||||||
|
|
||||||
|
|
||||||
func set_node_text(i_col: int, i_row: int, val: String) -> void:
|
func set_node_text(i_col: int, i_row: int, val: String) -> void:
|
||||||
@@ -350,12 +344,12 @@ func set_rows_state(rows: Array) -> void:
|
|||||||
for i_row in rows.size():
|
for i_row in rows.size():
|
||||||
for i_col in columns:
|
for i_col in columns:
|
||||||
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
||||||
nodes[name].pressed = rows[i_row][i_col]
|
nodes[name].button_pressed = rows[i_row][i_col]
|
||||||
|
|
||||||
|
|
||||||
func set_node_state(i_col: int, i_row: int, val: bool) -> void:
|
func set_node_state(i_col: int, i_row: int, val: bool) -> void:
|
||||||
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
||||||
nodes[key].pressed = val
|
nodes[key].button_pressed = val
|
||||||
|
|
||||||
|
|
||||||
func set_node_frame(i_col: int, i_row: int, name: String, val: int) -> void:
|
func set_node_frame(i_col: int, i_row: int, name: String, val: int) -> void:
|
||||||
@@ -413,10 +407,10 @@ func get_row(i_row: int) -> Array:
|
|||||||
|
|
||||||
|
|
||||||
func get_node_rect(i_col: int, i_row: int, rect: Array) -> void:
|
func get_node_rect(i_col: int, i_row: int, rect: Array) -> void:
|
||||||
assert(rect.size() >= 4, 'ошибка: мало элементов для возврата результата')
|
assert(rect.size() >= 4) #,'ошибка: мало элементов для возврата результата')
|
||||||
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
var key: = get_node_key(NODE_KEY_FORMAT, i_col, i_row)
|
||||||
var cell = nodes[key]
|
var cell = nodes[key]
|
||||||
rect[0] = cell.rect_position.x
|
rect[0] = cell.position.x
|
||||||
rect[1] = cell.rect_position.y
|
rect[1] = cell.position.y
|
||||||
rect[2] = cell.rect_size.x
|
rect[2] = cell.size.x
|
||||||
rect[3] = cell.rect_size.y
|
rect[3] = cell.size.y
|
||||||
|
|||||||
30
threats.gd
30
threats.gd
@@ -12,11 +12,11 @@ const TableCellType5 = preload('res://ячейка-2.tscn')
|
|||||||
const TableCellType6 = preload('res://кнопка-5.tscn')
|
const TableCellType6 = preload('res://кнопка-5.tscn')
|
||||||
|
|
||||||
# Индекс колонки: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
|
# Индекс колонки: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
|
||||||
const TABLE_HEADERS = ['ID Цели', 'Кур. уг.', 'Частота', 'Ш. диап.', 'Ампл.', 'T обнар.', 'Мод.', 'Реж. см. F', 'Ск. пер.', 'Протокол', 'Ст. дол.', 'Ст. шир.', 'Cт. выс.', 'Тек. дол.', 'Тек. шир.', 'Тек. выс.', ]
|
const TABLE_HEADERS = ['ID Цели', 'Курc.град', 'Частота', 'Ш. диап.', 'Ампл.', 'T обнар.', 'Мод.', 'Реж. см. F', 'Ск. пер.', 'Протокол', 'Ст. дол.', 'Ст. шир.', 'Cт. выс.', 'Тек. дол.', 'Тек. шир.', 'Тек. выс.', ]
|
||||||
const TABLE_HEADER_TYPES = [ TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4]
|
const TABLE_HEADER_TYPES = [ TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4, TableCellType4]
|
||||||
const TABLE_HEADER_ALIGNMENTS = [ HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER]
|
const TABLE_HEADER_ALIGNMENTS = [ HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER]
|
||||||
const TABLE_ROW_TYPES = [ TableCellType1, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType6, TableCellType6, TableCellType5, TableCellType6, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType5]
|
const TABLE_ROW_TYPES = [ TableCellType1, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType6, TableCellType6, TableCellType5, TableCellType6, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType5, TableCellType5]
|
||||||
const TABLE_ROW_ALIGNMENTS = [ HALIGN_CENTER, HALIGN_LEFT, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER, HALIGN_CENTER]
|
const TABLE_ROW_ALIGNMENTS = [ HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_LEFT, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER, HORIZONTAL_ALIGNMENT_CENTER]
|
||||||
const TABLE_COLUMN_SIZES = [ 82, 82, 82, 82, 82, 90, 150, 150, 80, 150, 82, 82, 82, 82, 82, 82]
|
const TABLE_COLUMN_SIZES = [ 82, 82, 82, 82, 82, 90, 150, 150, 80, 150, 82, 82, 82, 82, 82, 82]
|
||||||
|
|
||||||
const COLUMN_ID = 0 # Идентификатор цели
|
const COLUMN_ID = 0 # Идентификатор цели
|
||||||
@@ -142,7 +142,7 @@ class Threat:
|
|||||||
|
|
||||||
func _check_value(val):
|
func _check_value(val):
|
||||||
if val[1]:
|
if val[1]:
|
||||||
return String(val[0])
|
return '%s' % val[0]
|
||||||
else:
|
else:
|
||||||
return ''
|
return ''
|
||||||
|
|
||||||
@@ -234,7 +234,7 @@ class Threat:
|
|||||||
row.lat[1] = Tools.check_empty(value)
|
row.lat[1] = Tools.check_empty(value)
|
||||||
return value
|
return value
|
||||||
|
|
||||||
func set_alt(val):
|
func set_alt_pressed(val):
|
||||||
var value = float(val)
|
var value = float(val)
|
||||||
value = Tools.check_len(val, value)
|
value = Tools.check_len(val, value)
|
||||||
row.alt[0] = value
|
row.alt[0] = value
|
||||||
@@ -269,11 +269,11 @@ func init_treats(header, table, btn_add, btn_del): # Инициализац
|
|||||||
init_table(header, TABLE_COLUMN_SIZES)
|
init_table(header, TABLE_COLUMN_SIZES)
|
||||||
init_table(table, TABLE_COLUMN_SIZES)
|
init_table(table, TABLE_COLUMN_SIZES)
|
||||||
table.align_to_left_bottom(header, Vector2(0, 2))
|
table.align_to_left_bottom(header, Vector2(0, 2))
|
||||||
table.connect('row_pressed', self, 'on_row_pressed', [table])
|
table.connect('row_pressed', Callable(self, 'on_row_pressed').bind(table))
|
||||||
table.set_callbacks(self, 'text_entered', 'on_edit_entry', TABLE_ENTRY_COLUMNS, [table])
|
table.set_callbacks(self, 'text_submitted', 'on_edit_entry', TABLE_ENTRY_COLUMNS, [table])
|
||||||
table.set_callbacks(self, 'item_selected', 'on_item_selected', COLUMN_OPT_BTN, [table])
|
table.set_callbacks(self, 'item_selected', 'on_item_selected', COLUMN_OPT_BTN, [table])
|
||||||
btn_add.connect('button_up', self, 'on_btn_add', [table])
|
btn_add.connect('button_up', Callable(self, 'on_btn_add').bind(table))
|
||||||
btn_del.connect('button_up', self, 'on_btn_del', [table])
|
btn_del.connect('button_up', Callable(self, 'on_btn_del').bind(table))
|
||||||
|
|
||||||
|
|
||||||
func selector_color_proc(_i_row: int):
|
func selector_color_proc(_i_row: int):
|
||||||
@@ -346,7 +346,7 @@ func set_value(val : String, treat_id : String, column : int):
|
|||||||
COLUMN_LON:
|
COLUMN_LON:
|
||||||
return treat.set_lat(val)
|
return treat.set_lat(val)
|
||||||
COLUMN_ALT:
|
COLUMN_ALT:
|
||||||
return treat.set_alt(val)
|
return treat.set_alt_pressed(val)
|
||||||
|
|
||||||
|
|
||||||
func on_row_pressed(i_row: int, table):
|
func on_row_pressed(i_row: int, table):
|
||||||
@@ -357,12 +357,12 @@ func on_row_pressed(i_row: int, table):
|
|||||||
func on_btn_add(table):
|
func on_btn_add(table):
|
||||||
var id = pop_id()
|
var id = pop_id()
|
||||||
var threat : = Threat.new(id)
|
var threat : = Threat.new(id)
|
||||||
treats[String(id)] = threat
|
treats['%d' % id] = threat
|
||||||
var row = threat.update_rows()
|
var row = threat.update_rows()
|
||||||
table.add_row(TABLE_ROW_TYPES)
|
table.add_row(TABLE_ROW_TYPES)
|
||||||
table.set_row_text(table.get_rows_count()-1, row)
|
table.set_row_text(table.get_rows_count()-1, row)
|
||||||
init_opt_btns(table.get_rows_count()-1, table)
|
init_opt_btns(table.get_rows_count()-1, table)
|
||||||
table.set_callbacks(self, 'text_entered', 'on_edit_entry', TABLE_ENTRY_COLUMNS, [])
|
table.set_callbacks(self, 'text_submitted', 'on_edit_entry', TABLE_ENTRY_COLUMNS, [])
|
||||||
table.set_callbacks(self, 'item_selected', 'on_item_selected', COLUMN_OPT_BTN, [])
|
table.set_callbacks(self, 'item_selected', 'on_item_selected', COLUMN_OPT_BTN, [])
|
||||||
|
|
||||||
|
|
||||||
@@ -380,7 +380,7 @@ func pop_id():
|
|||||||
var id = 0
|
var id = 0
|
||||||
if len(id_array):
|
if len(id_array):
|
||||||
id = id_array[0]
|
id = id_array[0]
|
||||||
id_array.remove(0)
|
id_array.remove_at(0)
|
||||||
return id
|
return id
|
||||||
|
|
||||||
|
|
||||||
@@ -398,6 +398,6 @@ func get_threats_data():
|
|||||||
for key in treats:
|
for key in treats:
|
||||||
var data = treats[key].get_data()
|
var data = treats[key].get_data()
|
||||||
data_to_json['mis'].append(data)
|
data_to_json['mis'].append(data)
|
||||||
var json = to_json(data_to_json)
|
var json = JSON.new().stringify(data_to_json)
|
||||||
var pac = json.to_utf8()
|
var pac = json.to_utf8_buffer()
|
||||||
return pac
|
return pac
|
||||||
|
|||||||
@@ -4,12 +4,12 @@
|
|||||||
bg_color = Color( 1, 0.596078, 0.4, 1 )
|
bg_color = Color( 1, 0.596078, 0.4, 1 )
|
||||||
|
|
||||||
[node name="heder" type="Label"]
|
[node name="heder" type="Label"]
|
||||||
margin_right = 120.0
|
offset_right = 120.0
|
||||||
margin_bottom = 30.0
|
offset_bottom = 30.0
|
||||||
size_flags_horizontal = 15
|
size_flags_horizontal = 15
|
||||||
size_flags_vertical = 15
|
size_flags_vertical = 15
|
||||||
custom_colors/font_color = Color( 0.0313726, 0.105882, 0.184314, 1 )
|
theme_override_colors/font_color = Color( 0.0313726, 0.105882, 0.184314, 1 )
|
||||||
custom_styles/normal = SubResource( 1 )
|
theme_override_styles/normal = SubResource( 1 )
|
||||||
align = 1
|
align = 1
|
||||||
valign = 1
|
valign = 1
|
||||||
clip_text = true
|
clip_text = true
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/индикатор-1-0.png-fc0a1949f86e54aad24513db3cf620a1.stex"
|
uid="uid://dag8n0gknjwak"
|
||||||
|
path="res://.godot/imported/индикатор-1-0.png-fc0a1949f86e54aad24513db3cf620a1.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://индикатор-1-0.png"
|
source_file="res://индикатор-1-0.png"
|
||||||
dest_files=[ "res://.import/индикатор-1-0.png-fc0a1949f86e54aad24513db3cf620a1.stex" ]
|
dest_files=["res://.godot/imported/индикатор-1-0.png-fc0a1949f86e54aad24513db3cf620a1.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/индикатор-1-1.png-8b27c7b615854227f833f39bac77ddc2.stex"
|
uid="uid://b3ext3w4ftgg2"
|
||||||
|
path="res://.godot/imported/индикатор-1-1.png-8b27c7b615854227f833f39bac77ddc2.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://индикатор-1-1.png"
|
source_file="res://индикатор-1-1.png"
|
||||||
dest_files=[ "res://.import/индикатор-1-1.png-8b27c7b615854227f833f39bac77ddc2.stex" ]
|
dest_files=["res://.godot/imported/индикатор-1-1.png-8b27c7b615854227f833f39bac77ddc2.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/кнопка-3-0.png-5f27389cf7d8b3614e031e6b8d168b3c.stex"
|
uid="uid://cf0jds8v6lqin"
|
||||||
|
path="res://.godot/imported/кнопка-3-0.png-5f27389cf7d8b3614e031e6b8d168b3c.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://кнопка-3-0.png"
|
source_file="res://кнопка-3-0.png"
|
||||||
dest_files=[ "res://.import/кнопка-3-0.png-5f27389cf7d8b3614e031e6b8d168b3c.stex" ]
|
dest_files=["res://.godot/imported/кнопка-3-0.png-5f27389cf7d8b3614e031e6b8d168b3c.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
[remap]
|
[remap]
|
||||||
|
|
||||||
importer="texture"
|
importer="texture"
|
||||||
type="StreamTexture"
|
type="CompressedTexture2D"
|
||||||
path="res://.import/кнопка-3-1.png-d6f5584c24056a03a792e757c3c765b0.stex"
|
uid="uid://ddxxauugcc14e"
|
||||||
|
path="res://.godot/imported/кнопка-3-1.png-d6f5584c24056a03a792e757c3c765b0.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
@@ -10,26 +11,24 @@ metadata={
|
|||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://кнопка-3-1.png"
|
source_file="res://кнопка-3-1.png"
|
||||||
dest_files=[ "res://.import/кнопка-3-1.png-d6f5584c24056a03a792e757c3c765b0.stex" ]
|
dest_files=["res://.godot/imported/кнопка-3-1.png-d6f5584c24056a03a792e757c3c765b0.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
compress/mode=0
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
compress/lossy_quality=0.7
|
compress/lossy_quality=0.7
|
||||||
compress/hdr_mode=0
|
compress/hdr_compression=1
|
||||||
compress/bptc_ldr=0
|
|
||||||
compress/normal_map=0
|
compress/normal_map=0
|
||||||
flags/repeat=0
|
compress/channel_pack=0
|
||||||
flags/filter=true
|
mipmaps/generate=false
|
||||||
flags/mipmaps=false
|
mipmaps/limit=-1
|
||||||
flags/anisotropic=false
|
roughness/mode=0
|
||||||
flags/srgb=2
|
roughness/src_normal=""
|
||||||
process/fix_alpha_border=true
|
process/fix_alpha_border=true
|
||||||
process/premult_alpha=false
|
process/premult_alpha=false
|
||||||
process/HDR_as_SRGB=false
|
|
||||||
process/invert_color=false
|
|
||||||
process/normal_map_invert_y=false
|
process/normal_map_invert_y=false
|
||||||
stream=false
|
process/hdr_as_srgb=false
|
||||||
size_limit=0
|
process/hdr_clamp_exposure=false
|
||||||
detect_3d=true
|
process/size_limit=0
|
||||||
svg/scale=1.0
|
detect_3d/compress_to=1
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
[gd_scene load_steps=3 format=2]
|
[gd_scene load_steps=3 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://кнопка-3-1.png" type="Texture" id=1]
|
[ext_resource path="res://кнопка-3-1.png" type="Texture2D" id=1]
|
||||||
[ext_resource path="res://кнопка-3-0.png" type="Texture" id=2]
|
[ext_resource path="res://кнопка-3-0.png" type="Texture2D" id=2]
|
||||||
|
|
||||||
[node name="TextureButton" type="TextureButton"]
|
[node name="TextureButton" type="TextureButton"]
|
||||||
modulate = Color( 1.5, 1.5, 1.5, 1 )
|
modulate = Color( 1.5, 1.5, 1.5, 1 )
|
||||||
margin_right = 140.0
|
offset_right = 140.0
|
||||||
margin_bottom = 34.0
|
offset_bottom = 34.0
|
||||||
toggle_mode = true
|
toggle_mode = true
|
||||||
action_mode = 0
|
action_mode = 0
|
||||||
texture_normal = ExtResource( 2 )
|
texture_normal = ExtResource( 2 )
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
[gd_scene load_steps=3 format=2]
|
[gd_scene load_steps=3 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://индикатор-1-1.png" type="Texture" id=1]
|
[ext_resource path="res://индикатор-1-1.png" type="Texture2D" id=1]
|
||||||
[ext_resource path="res://индикатор-1-0.png" type="Texture" id=2]
|
[ext_resource path="res://индикатор-1-0.png" type="Texture2D" id=2]
|
||||||
|
|
||||||
[node name="indicator_1" type="TextureButton"]
|
[node name="indicator_1" type="TextureButton"]
|
||||||
modulate = Color( 1, 0.596078, 0.4, 1 )
|
modulate = Color( 1, 0.596078, 0.4, 1 )
|
||||||
margin_right = 35.0
|
offset_right = 35.0
|
||||||
margin_bottom = 29.0
|
offset_bottom = 29.0
|
||||||
toggle_mode = true
|
toggle_mode = true
|
||||||
button_mask = 0
|
button_mask = 0
|
||||||
texture_normal = ExtResource( 2 )
|
texture_normal = ExtResource( 2 )
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
[gd_scene format=2]
|
[gd_scene format=2]
|
||||||
|
|
||||||
[node name="OptionButton" type="OptionButton"]
|
[node name="OptionButton" type="OptionButton"]
|
||||||
margin_right = 80.0
|
offset_right = 80.0
|
||||||
margin_bottom = 34.0
|
offset_bottom = 34.0
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
[gd_scene format=2]
|
[gd_scene format=2]
|
||||||
|
|
||||||
[node name="Label" type="Label"]
|
[node name="Label" type="Label"]
|
||||||
margin_right = 122.0
|
offset_right = 122.0
|
||||||
margin_bottom = 34.0
|
offset_bottom = 34.0
|
||||||
custom_colors/font_color = Color( 1, 0.596078, 0.4, 1 )
|
theme_override_colors/font_color = Color( 1, 0.596078, 0.4, 1 )
|
||||||
align = 1
|
align = 1
|
||||||
valign = 1
|
valign = 1
|
||||||
clip_text = true
|
clip_text = true
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
[gd_scene format=2]
|
[gd_scene format=2]
|
||||||
|
|
||||||
[node name="LineEdit" type="LineEdit"]
|
[node name="LineEdit" type="LineEdit"]
|
||||||
margin_right = 82.0
|
offset_right = 82.0
|
||||||
margin_bottom = 34.0
|
offset_bottom = 34.0
|
||||||
custom_colors/font_color = Color( 1, 0.596078, 0.4, 1 )
|
theme_override_colors/font_color = Color( 1, 0.596078, 0.4, 1 )
|
||||||
context_menu_enabled = false
|
context_menu_enabled = false
|
||||||
shortcut_keys_enabled = false
|
shortcut_keys_enabled = false
|
||||||
middle_mouse_paste_enabled = false
|
middle_mouse_paste_enabled = false
|
||||||
caret_blink = true
|
caret_blink = true
|
||||||
caret_blink_speed = 0.13
|
caret_blink_interval = 0.13
|
||||||
|
|||||||
Reference in New Issue
Block a user