[+] Add Driving License to Interaction Menu and as 'Object' to show other Players via the Interaction menu

This commit is contained in:
Lukas Moungos
2019-11-02 18:36:17 +01:00
parent e3c3949f1b
commit c46c778a47
14 changed files with 296 additions and 26 deletions

View File

@@ -0,0 +1,34 @@

$(document).ready(function () {
mp.trigger('CEF:LicenseLoaded');
});
function add_licenses(info) {
infoArr = JSON.parse(info);
console.log(infoArr);
for (var i = 0; i < infoArr.length; i++) {
var Schein = "";
if (infoArr[i] == true) {
if (i == 0) {
Schein = "Auto";
} else if (i == 1) {
Schein = "Motorrad";
} else if (i == 2) {
Schein = "Flugzeug";
}
}
$('#'+i).append(""+Schein);
}
}
function add_licensesholder(info) {
name = JSON.parse(info);
$('#name').append("<p>" + name + "</p>");
}