[+] Add Driving License to Interaction Menu and as 'Object' to show other Players via the Interaction menu
This commit is contained in:
35
ReallifeGamemode.Client/assets/css/licenses/schein.css
Normal file
35
ReallifeGamemode.Client/assets/css/licenses/schein.css
Normal file
@@ -0,0 +1,35 @@
|
||||
html, body {
|
||||
overflow: hidden;
|
||||
}
|
||||
#schein {
|
||||
overflow: hidden;
|
||||
position: absolute;
|
||||
right: 0px;
|
||||
bottom: 0px;
|
||||
animation: 1s ease-out 0s 1 slideInFromLeft;
|
||||
}
|
||||
|
||||
#erworbene {
|
||||
overflow: hidden;
|
||||
Position: absolute;
|
||||
right: 15%;
|
||||
top: 46%;
|
||||
}
|
||||
|
||||
#name {
|
||||
overflow: hidden;
|
||||
Position: absolute;
|
||||
left: 40%;
|
||||
top: 24.4%;
|
||||
}
|
||||
|
||||
|
||||
@keyframes slideInFromLeft {
|
||||
0% {
|
||||
transform: translateY(100%);
|
||||
}
|
||||
|
||||
100% {
|
||||
transform: translateX(0);
|
||||
}
|
||||
}
|
||||
26
ReallifeGamemode.Client/assets/html/licenses/scheine.html
Normal file
26
ReallifeGamemode.Client/assets/html/licenses/scheine.html
Normal file
@@ -0,0 +1,26 @@
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<link rel="stylesheet" href="package://assets/css/licenses/schein.css">
|
||||
</head>
|
||||
<body scroll="no">
|
||||
<div id="schein">
|
||||
|
||||
<img src="package://assets/img/licenses/schein.png">
|
||||
|
||||
<div id="name">
|
||||
|
||||
</div>
|
||||
|
||||
<div id="erworbene">
|
||||
<p id="0"></p>
|
||||
<p id="1"></p>
|
||||
<p id="2"></p>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>
|
||||
<script src="package://assets/js/licenses/scheine.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
BIN
ReallifeGamemode.Client/assets/img/licenses/schein.png
Normal file
BIN
ReallifeGamemode.Client/assets/img/licenses/schein.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 141 KiB |
34
ReallifeGamemode.Client/assets/js/licenses/scheine.js
Normal file
34
ReallifeGamemode.Client/assets/js/licenses/scheine.js
Normal 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>");
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user