> For the complete documentation index, see [llms.txt](https://daburnergermany.gitbook.io/mymdt/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://daburnergermany.gitbook.io/mymdt/info/sync-config.sync.lua/players.md).

# Players

{% hint style="info" %}
If the exports are active and the sync is also active, the sync is preferred and the exports are deactivated.
{% endhint %}

**Configure in config.sync.lua**

Make sure that in Config.Sync the entry active is set to true and in Types the Users is set to true.

<figure><img src="https://lh3.googleusercontent.com/aAQJ2lOXy-waO8I34KAhXktxV0FRImsAz7xVzikbpE-2IDaQMwpQZB4ytTK0zBj6aoHIxf1liVaItV4MfUx8g4M-Hi2SeOPf9U0Z-AkDIB9PuhphRTd5fAPoAoYYfV0JZKsczy7IoEYtJ3TYpxDoJM0" alt=""><figcaption><p>Config.Sync is now SyncSettings.MainData</p></figcaption></figure>

<br>

after script restart it should import all users to your police and medic MDT.

## **Add data to the sync**

1. Open the sync\_functions.lua with any ide (notepad++, visual studio code)
   1. /server/sync/files.lua&#x20;
2. Search in the file the FormatData function for your Framework
   1. ESX : myMDT\_core\_sync.files.FormatData\_ESX
   2. QB: myMDT\_core\_sync.files.FormatData\_QB

### **Examples**

<figure><img src="/files/ENw6SvyCpufDTiwteSjp" alt=""><figcaption></figcaption></figure>

The Important part is now where the curly brackets from the return

<figure><img src="/files/aLTAZOuhkHJQjWiSBtyp" alt=""><figcaption></figcaption></figure>

if your players/users table stores the size of the users than you simply need to add this like following:

<figure><img src="/files/F18GBZiWsMltzDUTQDoX" alt=""><figcaption><p>size = inputData.size added</p></figcaption></figure>

on the left hand is the column name/key from myMDT\_core, on the right side is the column from your players/users table.

**Never touch this keys : id, player\_id, fromsystem**

### **Available Keys**

* alias
* sex
* phone
* size
* birth
* eyecolor
* haircolor
* blood\_type
* weight
* allergies
* known\_illnesses

### **Format Birthdate**

If your table doesn’t store the birthdate in the format YYYY-MM-DD you can use the function convertDateForMDT

Usage for DD.MM.YYYY

```
myMDT_core_sync.files.convertDateForMDT(<here date>, ".", "dd.mm.yyyy")
```

Usage for YYYY/MM/DD

```
myMDT_core_sync.files.convertDateForMDT(<here date>, "/", "yyyy/mm/dd")
```

Usage for YYYY/DD/MM

```
myMDT_core_sync.files.convertDateForMDT(<here date>, "/", "yyyy/dd/mm")
```

If the Birthdate is in a wrong format the Javascript will throw an error and will not display the birth


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://daburnergermany.gitbook.io/mymdt/info/sync-config.sync.lua/players.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
