-
Notifications
You must be signed in to change notification settings - Fork 0
/
targetInit.m
39 lines (37 loc) · 1.67 KB
/
targetInit.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
function TargetInit(id)
% This function is used to initialize pos and draw the robot's body.
global Target numofrobots
% Define Target
m = 13;
% Target(1).x = [16, 18];
% Target(2).x = [21.1332941170788,26.0857240533298];
% Target(3).x = [24.8375965968732,22.1482174797537];%
% Target(4).x = [22.3056384222507,20.8366994405982];
% Target(5).x = [20.4638161167498,19.5844000304649];
% Target(7).x = [18,19.1507837665802];
% Target(8).x = [22.7885399259971,28.5602161262768];
% Target(6).x = [22.1267811755082,23.6042020669595];
% Target(9).x = [17.1799899423913,22.8767018979164];
% Target(10).x = [18.6288634007536,25.5637069768154];
% Target(11).x = [17.6084891516628,28.1551209078760];
% Target(12).x = [15.2698965599490,29.5745082737879];
% Target(13).x = [19.8346228135871,29.6149185828548];
% Target(14).x = [21.1878429237510,28.8507725530829];
% Target(15).x = [24.1795783927349,30.1381347073212];
Target(1).x = [16, 18];
Target(2).x = [19.9405850418730,18.6868693673231];
Target(3).x = [22.0868767138747,22.0622852022531];%
Target(4).x = [18.1113220981812,22.5038341776093];
Target(5).x = [13.9219758302599,28.8418753915935];
Target(6).x = [10.0964721166419,27.6733201566582];
Target(7).x = [14.9714752450756,24.9820112776251];
Target(8).x = [8.87722963223302,31.4829720783188];
Target(9).x = [5.28551890947586,33.2435441683030];
Target(10).x = [6.36914206270733,29.3931207030487];
Target(11).x = [3.40504719042875,28.9303663533860];
Target(12).x = [2.15213206069641,32.7290771449161];
Target(13).x = [10.5363960711406,30.0471042039401];
Target(14).x = [2.65675804164958,35.7920639996196];
Target(15).x = [5.51801599992800,36.6938416308505];
Target(id).status = "free";
end