Skip to content

Samuels-Development/sd-phone

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

220 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sd-phone (THIS IS A BETA RELEASE, WILL HAVE ISSUES)

An iOS-themed smartphone for FiveM. 45+ server-backed apps, real app accounts, a live game-view camera and online multiplayer games. Ships its own custom phone props: eight phone items in eight colours, each tinting both the on-screen frame and the custom prop model held in hand. A unique phone system as well as sim cards can be enabled!

A drop-in lb-phone replacement. Scripts and custom apps written against lb-phone's exports and events keep running unmodified, and a first-boot migration carries your players across rather than resetting them: phone numbers and lock passcodes, contacts, call history, blocked numbers, SMS threads including groups, photos and albums, and notes.

If sd-phone is useful to you, please ⭐ the repo. Issues and pull requests are always welcome.

Live demo

Release Downloads Stars Discord Documentation

Framework Voice Compatibility

Live demo · Documentation · Store · Discord


Preview

image bb6 THIS mb3

Overview

sd-phone is a complete smartphone experience: lockscreen with passcode and Face Unlock, customizable homescreen with a real app switcher, notification banners with persistent server-authoritative unread badges, and a full catalog of apps backed by their own server modules. The UI is a React app rendered inside a real iPhone bezel; the phone is held as an in-hand prop, tints to the colour of the phone item you used, and keeps working while you walk.

Everything player-facing is translatable, apps resume where you left them, and the phone auto-detects your framework, inventory, banking, housing, garage, and voice resources with zero config flags.

Powered by Fivemanage

Fivemanage

sd-phone is partnered with Fivemanage for media hosting

The Camera, Photos and Voice Memos apps need somewhere to store what they capture. sd-phone uses Fivemanage for that: every screenshot, camera video and voice recording uploads to Fivemanage and comes back as a fast CDN URL, so you never run your own media server. It is the CDN and logging platform trusted by thousands of FiveM servers.

A free Fivemanage Media API token is required for photo, video and voice-note uploads to work. In the Fivemanage dashboard open the Tokens tab, create a token of type Media, and paste it into configs/server/apikeys.lua under FivemanageMedia. Without a key the camera and recorders still open, but nothing uploads or saves.

Get started with Fivemanage

The free tier is plenty for most servers.

Apps

Communication Phone (1:1, group and company calls over pma-voice), Messages (SMS, group threads, GIFs, money and location cards), Mail (multi-account, global inboxes), Groups, Dark Chat, Radio, Find Friends
Social Photogram (posts, stories, DMs, real live video streaming), Birdy, Cherry, Vibez, Streaks, all on a shared accounts engine with registration, sign-in, and password resets delivered in-game
Camera & media Camera (live game view: photos, video with voice capture, selfie mode), Photos, Music (with AirShare library sharing), Voice Memos
World Maps (CDN-streamed tiles, routing, pins), Garages, Homes, Wallet, Services (company directory, dispatch messaging, phone multijob), Ryde (player-to-player ride hailing), Weazel News, Pages, Marketplace, Review, Weather, Stocks
Games Chess, Connect Four, Battleship and Wordle with online lobbies, plus Blackjack, Cookie, Flappy, Blocks, Climber and Rail Runner with server-side leaderboards
Utilities Clock (alarms), Calendar, Notes (with sketches), Calculator, Compass, Health, Passwords, App Store, Settings

Highlights

  • Real accounts engine. Social apps use actual registration and login, with verification codes and password resets delivered by in-game mail or SMS. Accounts are global, not per-character-slot.
  • Live game-view camera. The Camera app renders the world into the phone screen in real time; video clips record your microphone and nearby players' voices.
  • Photogram Live. Stream real encoded video to other players' phones, with clean late-joins.
  • Deep world integration. Garages and Homes bridge across ten-plus garage and housing systems; Wallet reads your framework bank; Services maps jobs to callable, messageable companies; Weather mirrors the in-game sky.
  • Custom apps. Other resources can put their own apps on the phone: one export call turns any webpage into an installable app with icons, badges, notifications, popups and an App Store listing. Custom apps built for lb-phone run unmodified. Start from the app templates (plain JS, React JS/TS, Vue 3, Svelte 5) and the custom app guide.
  • lb-phone drop-in compatibility. Third-party scripts written against lb-phone's exports and events keep working unmodified, and a one-command migrator imports lb-phone player data. See the compatibility docs.

For developers

The phone ships a full integration surface, documented at docs.samueldev.shop:

  • Server exports for sending mail, messages and notifications, starting calls, managing contacts, resolving numbers to players, logging transactions, posting news, and more.
  • Client exports for opening the phone, deep-linking into apps, and gating phone use.
  • Custom apps for shipping your own apps on the phone, with ready-made templates for plain JS, React, Vue and Svelte. Apps written for lb-phone register and run unmodified.
  • First-party events on every lifecycle moment: messages, mail, calls, transactions, posts, contacts.
  • lb-phone compatibility covering exports, events, and dependency 'lb-phone' lines.
-- A taste: text a player from a job script
exports['sd-phone']:sendSystemMessage('555-0199', 'LS Dispatch', targetNumber, 'New tow request at Legion Square.')

-- React to any SMS being sent
AddEventHandler('sd-phone:server:messages:sent', function(m)
    print(('%s texted %s'):format(m.senderNumber, m.targetNumber))
end)

Compatibility

Layer Supported
Frameworks QBCore, QBox, ESX (auto-detected)
Inventories ox_inventory, tgiann-inventory, qb-inventory, qs-inventory(-pro), origen_inventory, codem-inventory, jaksam_inventory, lj-inventory, ps-inventory
Voice pma-voice
Housing 9 housing systems for the Homes app
Garages 10 garage systems for the Garages app
Notify ox_lib (default), lation_ui (opt-in), framework-native fallback

Installation

Important

Grab the packaged sd-phone-*.zip from the latest release. The green Code → Download ZIP button gives you source only, with no web/build/, and the phone will open blank.

Prefer the full walkthrough? docs.samueldev.shop/resources/phone/installation

Dependencies

Resource What it is for
ox_lib Shared library
oxmysql Database access
sd-phone-props Streams the in-hand phone models

1. Start the resources

Extract sd-phone and sd-phone-props into your resources folder, then start them after their dependencies:

ensure ox_lib
ensure oxmysql
ensure sd-phone-props
ensure sd-phone

Database tables create themselves on first boot.

2. Add the phone items

One item per frame colour:

phone_black   phone_blue     phone_green   phone_orange
phone_pink    phone_purple   phone_red     phone_yellow

Ready-made ox_inventory definitions live in the installation docs, and the item icons ship in this repo's images/ folder.

Players can also open the phone with a keybind (F1 by default), which still requires owning one of these items.

3. Add your API keys

In configs/server/apikeys.lua:

Key Needed for
FivemanageMedia Required. Camera, Photos and Voice Memos uploads. Create a free Fivemanage token of type Media. Without it those apps open, but nothing uploads or saves.
Giphy Optional. The GIF picker in Messages. Free key from developers.giphy.com.

Building from source

Cloned the repo instead of using a release? Build the UI yourself:

cd web
npm ci
npm run build

The output lands in the gitignored web/build/, and the server logs a clear error on boot if it is missing.

About

No description, website, or topics provided.

Resources

Code of conduct

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages