Solstice-CyberNotify

Welcome to the Cyberpunk Notification System! This resource adds stylish, animated notifications to your FiveM server with a distinct cyberpunk aesthetic.

Basic Usage

exports['Solstice-CyberNotify']:ShowNotification(message, type, duration)

Parameters

  • message: Text to display

  • type: Notification type (default: 'info')

  • duration: Display time in milliseconds (default: 5000)

Default Types

-- Info notification
exports['Solstice-CyberNotify']:ShowNotification('Server restarting in 5 minutes', 'info')

-- Success notification
exports['Solstice-CyberNotify']:ShowNotification('Payment received', 'success')

-- Error notification
exports['Solstice-CyberNotify']:ShowNotification('Transaction failed', 'error')

-- Warning notification
exports['Solstice-CyberNotify']:ShowNotification('Low health', 'warning')

-- SMS notification 
exports['Solstice-CyberNotify']:ShowNotification('New message received', 'sms')

Test Command

Use /testnotify to see all notification types in action.

Adding New Notification Types

  1. Open ui/main.js

  2. Locate the notificationTypes object

  3. Add your new type following this format:

javascriptCopythis.notificationTypes = {
    // Existing types...
    
    // Add your new type here
    police: { 
        icon: 'fas fa-shield-alt',  // FontAwesome icon
        label: 'POLICE'             // Display label
    },
    
    medic: {
        icon: 'fas fa-ambulance',
        label: 'MEDIC'
    }
};

After adding new types, use them like any other type:

exports['Solstice-CyberNotify']:ShowNotification('Officer requested backup', 'police')

Available Icons

  • You can use any FontAwesome Free icon

  • Use the icon's class name in the icon property

Troubleshooting

If notifications aren't showing:

  1. Ensure the resource is started

  2. Check for client-side errors

  3. Try /testnotify to verify system functionality

For additional support, open a ticket in discord.

Last updated

Was this helpful?