Camera nutzt elf Items in zwei Familien – die Digitalkamera und die Sofortbildkamera. Füge jedes davon zu deinem Inventar hinzu: Ein Item, das nicht existiert, kann weder vergeben, benutzt noch angezeigt werden. Kopiere dann die Icons in den Bildordner deines Inventars.
Item | Label | Was es macht |
|---|---|---|
| Camera | Die Digitalkamera. Beim Benutzen öffnet sich ihr Panel; von dort aus machst du Fotos. |
| Broken Camera | Eine Kamera, die den Geist aufgegeben hat. Ein Kameramodul repariert sie. |
| Camera Module | Repariert eine kaputte oder abgenutzte Kamera. Wird bei der Reparatur verbraucht. |
| Roll of Film | Lädt 24 Aufnahmen in die Kamera, die du dabeihast. |
| Photo | Ein Digitalfoto mit Bewertung, Ort, Datum und Fotograf. Zeig es her oder bewahre es in einem Album auf. |
| Photo Album | 120 Fächer für Digitalfotos. |
| Instant Camera | Druckt mit jeder Aufnahme eine Karte. |
| Instant Paper | Ein Blatt pro Karte. Allein nicht nutzbar – die Sofortbildkamera verwendet es. |
| Card | Eine gedruckte Karte: halten, umdrehen, zeigen, weitergeben, aufhängen. |
| Card Album | Seiten für die Karten, die du behalten willst. |
| Cork Board | Hängt an einer Wand; Karten werden daran angepinnt. |
Icons#
Die Icons für die Sofortbild-Items – instant_camera.png, instant_film.png, instant_photo.png, instant_album.png und cork_board.png – liegen im Ordner [images]/ des Downloads. Für die digitalen Items kannst du beliebige Icons nutzen, benannt nach dem Item: camera.png, broken_camera.png, camera_module.png, camera_film.png, photo.png und photo_album.png.
Inventar | Bildordner |
|---|---|
|
|
|
|
|
|
Bei ox_inventory und qs-inventory zeigt eine gedruckte Karte ihr eigenes Foto als Icon: Jede Karte schreibt
imageurlin ihre Metadaten, sodass eine Karte im Inventar wie das Bild aussieht, das sie enthält.
Item-Definitionen#
Wähle dein Inventar und füge den ganzen Block in dessen Items-Datei ein. Gewichte und Beschreibungen sind Vorschläge – ändere sie nach Belieben; behalte die Itemnamen.
In ox_inventory/data/items.lua. Die Zeile server = { export = 'qs-camera.useItem' } macht ein Item in ox_inventory benutzbar – behalte sie. Qbox-Server nutzen ox_inventory, also ist das auch ihr Tab.
['camera'] = {
label = 'Camera',
weight = 800,
stack = false,
close = true,
description = 'A digital camera. Every shot becomes a photo.',
server = { export = 'qs-camera.useItem' },
},
['broken_camera'] = {
label = 'Broken Camera',
weight = 800,
stack = false,
close = true,
description = 'It gave out. A camera module brings it back.',
server = { export = 'qs-camera.useItem' },
},
['camera_module'] = {
label = 'Camera Module',
weight = 100,
stack = true,
close = true,
description = 'Spare parts that repair a camera.',
server = { export = 'qs-camera.useItem' },
},
['camera_film'] = {
label = 'Roll of Film',
weight = 60,
stack = true,
close = true,
description = 'Twenty-four exposures.',
server = { export = 'qs-camera.useItem' },
},
['photo'] = {
label = 'Photo',
weight = 10,
stack = false,
close = true,
description = 'A photo, with where and when it was taken.',
server = { export = 'qs-camera.useItem' },
},
['photo_album'] = {
label = 'Photo Album',
weight = 400,
stack = false,
close = true,
description = 'Keeps your photos in one piece.',
server = { export = 'qs-camera.useItem' },
},
['instant_camera'] = {
label = 'Instant Camera',
weight = 900,
stack = false,
close = true,
description = 'Prints a card the moment you press the shutter. Needs instant paper.',
server = { export = 'qs-camera.useItem' },
},
['instant_film'] = {
label = 'Instant Paper',
weight = 10,
stack = true,
close = false,
description = 'One sheet per card.',
},
['instant_photo'] = {
label = 'Card',
weight = 10,
stack = false,
close = true,
description = 'A moment, printed.',
server = { export = 'qs-camera.useItem' },
},
['instant_album'] = {
label = 'Card Album',
weight = 400,
stack = false,
close = true,
description = 'Pages for the cards you want to keep.',
server = { export = 'qs-camera.useItem' },
},
['cork_board'] = {
label = 'Cork Board',
weight = 2000,
stack = false,
close = true,
description = 'Hangs on a wall. Pin cards to it.',
server = { export = 'qs-camera.useItem' },
},In qs-inventory/shared/items.lua. Neuere Versionen von qs-inventory listen die digitalen Items eventuell schon – behalte deine und füge nur die fehlenden hinzu.
['camera'] = { name = 'camera', label = 'Camera', weight = 800, type = 'item', image = 'camera.png', unique = true, useable = true, shouldClose = true, description = 'A digital camera. Every shot becomes a photo.' },
['broken_camera'] = { name = 'broken_camera', label = 'Broken Camera', weight = 800, type = 'item', image = 'broken_camera.png', unique = true, useable = true, shouldClose = true, description = 'It gave out. A camera module brings it back.' },
['camera_module'] = { name = 'camera_module', label = 'Camera Module', weight = 100, type = 'item', image = 'camera_module.png', unique = false, useable = true, shouldClose = true, description = 'Spare parts that repair a camera.' },
['camera_film'] = { name = 'camera_film', label = 'Roll of Film', weight = 60, type = 'item', image = 'camera_film.png', unique = false, useable = true, shouldClose = true, description = 'Twenty-four exposures.' },
['photo'] = { name = 'photo', label = 'Photo', weight = 10, type = 'item', image = 'photo.png', unique = true, useable = true, shouldClose = true, description = 'A photo, with where and when it was taken.' },
['photo_album'] = { name = 'photo_album', label = 'Photo Album', weight = 400, type = 'item', image = 'photo_album.png', unique = true, useable = true, shouldClose = true, description = 'Keeps your photos in one piece.' },
['instant_camera'] = { name = 'instant_camera', label = 'Instant Camera', weight = 900, type = 'item', image = 'instant_camera.png', unique = true, useable = true, shouldClose = true, description = 'Prints a card the moment you press the shutter. Needs instant paper.' },
['instant_film'] = { name = 'instant_film', label = 'Instant Paper', weight = 10, type = 'item', image = 'instant_film.png', unique = false, useable = false, shouldClose = false, description = 'One sheet per card.' },
['instant_photo'] = { name = 'instant_photo', label = 'Card', weight = 10, type = 'item', image = 'instant_photo.png', unique = true, useable = true, shouldClose = true, description = 'A moment, printed.' },
['instant_album'] = { name = 'instant_album', label = 'Card Album', weight = 400, type = 'item', image = 'instant_album.png', unique = true, useable = true, shouldClose = true, description = 'Pages for the cards you want to keep.' },
['cork_board'] = { name = 'cork_board', label = 'Cork Board', weight = 2000, type = 'item', image = 'cork_board.png', unique = true, useable = true, shouldClose = true, description = 'Hangs on a wall. Pin cards to it.' },In qb-core/shared/items.lua. Derselbe Block funktioniert für ps-inventory und lj-inventory.
['camera'] = { name = 'camera', label = 'Camera', weight = 800, type = 'item', image = 'camera.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'A digital camera. Every shot becomes a photo.' },
['broken_camera'] = { name = 'broken_camera', label = 'Broken Camera', weight = 800, type = 'item', image = 'broken_camera.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'It gave out. A camera module brings it back.' },
['camera_module'] = { name = 'camera_module', label = 'Camera Module', weight = 100, type = 'item', image = 'camera_module.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'Spare parts that repair a camera.' },
['camera_film'] = { name = 'camera_film', label = 'Roll of Film', weight = 60, type = 'item', image = 'camera_film.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'Twenty-four exposures.' },
['photo'] = { name = 'photo', label = 'Photo', weight = 10, type = 'item', image = 'photo.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'A photo, with where and when it was taken.' },
['photo_album'] = { name = 'photo_album', label = 'Photo Album', weight = 400, type = 'item', image = 'photo_album.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Keeps your photos in one piece.' },
['instant_camera'] = { name = 'instant_camera', label = 'Instant Camera', weight = 900, type = 'item', image = 'instant_camera.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Prints a card the moment you press the shutter. Needs instant paper.' },
['instant_film'] = { name = 'instant_film', label = 'Instant Paper', weight = 10, type = 'item', image = 'instant_film.png', unique = false, useable = false, shouldClose = false, combinable = nil, description = 'One sheet per card.' },
['instant_photo'] = { name = 'instant_photo', label = 'Card', weight = 10, type = 'item', image = 'instant_photo.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'A moment, printed.' },
['instant_album'] = { name = 'instant_album', label = 'Card Album', weight = 400, type = 'item', image = 'instant_album.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Pages for the cards you want to keep.' },
['cork_board'] = { name = 'cork_board', label = 'Cork Board', weight = 2000, type = 'item', image = 'cork_board.png', unique = true, useable = true, shouldClose = true, combinable = nil, description = 'Hangs on a wall. Pin cards to it.' },Behalte die Itemnamen genau wie oben. Es sind die Namen, die unter Items in
/cameraconfigaufgeführt sind, und das Script registriert beim Start unter diesen Namen, was jedes Item macht.
Was sich jedes Item merkt#
Alles wird am Item selbst gespeichert und reist mit ihm – tausche eine Kamera und ihr Zustand geht mit; verschenke ein Album und seine Fotos gehen auch mit.
Item | Trägt |
|---|---|
| Eine Seriennummer wie |
| Die Adresse des Bildes, einen Titel, Zone und Straße, Datum und Spielzeit, das Wetter, den Fotografen, die Qualität, die Bewertung, den Filter und den Zoom. |
| Die gedruckte Vorderseite, den Titel, die Notiz auf der Rückseite, das Papier, wer es aufgenommen hat, den Ort und das Datum. |
| Eine ID. Der Inhalt wird unter dieser ID in der Datenbank gespeichert und folgt dem Item, wohin es auch geht. |



