self icons

This commit is contained in:
Sylvain Gay 2023-09-06 18:00:41 +02:00
parent a5f8074a17
commit d135dd41e2
10 changed files with 20 additions and 3 deletions

View file

@ -83,7 +83,7 @@
socket = io({rejectUnauthorized: false, auth: {type:"Admin"}});
setup_socket_common();
setup_socket_common(-1);
//////////////////////////////////////////////////////////////////////////////
// INTERACTION

BIN
static/self_def.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
static/self_green.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
static/self_invi.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
static/self_orange.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
static/self_purple.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
static/self_track.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View file

@ -45,7 +45,7 @@
id = "%ID"; // %ID will be replaced by the real id.
socket = io({rejectUnauthorized: false, auth: {id: id, type:"conscrit"}});
setup_socket_common();
setup_socket_common(id);
//////////////////////////////////////////////////////////////////////////////
// SETTINGS -- CODE

View file

@ -65,7 +65,7 @@
id = "%ID"; // %ID will be replaced by the real id.
socket = io({rejectUnauthorized: false, auth: {id: id, type:"vieux"}});
setup_socket_common();
setup_socket_common(id);
//////////////////////////////////////////////////////////////////////////////
// SETTINGS -- State

View file

@ -13,6 +13,14 @@ var CircleIcon = L.Icon.extend({
}
});
var SelfIcon = L.Icon.extend({
options: {
iconSize: [20, 30],
iconAnchor: [10, 15],
popupAnchor: [0, 0]
}
});
var icons = [
new CircleIcon({ iconUrl: '/def.png' }),
new CircleIcon({ iconUrl: '/track.png' }),
@ -22,6 +30,15 @@ var icons = [
new CircleIcon({ iconUrl: '/orange.png' })
];
var self_icons = [
new SelfIcon({ iconUrl: '/self_def.png' }),
new SelfIcon({ iconUrl: '/self_track.png' }),
new SelfIcon({ iconUrl: '/self_invi.png' }),
new SelfIcon({ iconUrl: '/self_purple.png' }),
new SelfIcon({ iconUrl: '/self_green.png' }),
new SelfIcon({ iconUrl: '/self_orange.png' })
];
//////////////////////////////////////////////////////////////////////////////
// INIT MAP