Git Product home page Git Product logo

npwd's Introduction

Material-UI logo

NPWD

Monorepo structure

Apps

  • phone: The React code for NPWD.
  • game: Game releated scripts and code that runs on the client/server-side in FiveM.

Packages

  • npwd-hooks: Hooks used throughout external apps. Mainly to communicate with npwd through custom window events.
  • npwd-types: Auto-generated types from NPWD that can be used in external apps.
  • database: Database configuration and classes for each app
  • logger: Logging lib with winston
  • config: NPWD related config functions

Standalone Information & Installation

We have designed NPWD to be generally framework agnostic, meaning that it can easily be integrated with both popular open source frameworks like ESX & QBCore or any arbitary custom framework.

For further details on this system, please refer to our installation documentation.

You will also need screenshot-basic.

Technical Stack and Development

NPWD uses React + TypeScript to form the NUI front end and uses TypeScript (V8 runtime) for game scripts. You can find more technical information regarding the development of this project on our docs page here.

Feature Request & Issue Reporting

Please open an issue/enhancement on our Github Repo. This is the best way for us to track what needs to be resolved or improved upon.

Features

  • Optimized
    • 0.01 ms on idle and 0.05 while in use.
  • Twitter
    • Like, reply, retweet, report and delete your own Tweets.
    • Send emojis and images directly from the phone's gallery, or from an external url. Gifs too!
    • NPWD features discord logging so all reported tweets will be sent to the configured webhook.
    • Log tweets directly to discord with configured webhook.
  • Matchmaker
    • Like tinder but without all the bots. Swipe right into romance or rejection.
    • As of v1.0, there is no filter for sexual preference.
    • Don't want this app? Follow the documentation here to disable it.
  • Marketplace
    • Post an ad with/without a picture.
    • Choose a picture from your gallery or from a url.
    • Features calling/messaging icons so no need to provide your number.
  • Text Messaging
    • Send a message or an image taken straight from the phones Gallery.
    • Group messages
  • Calling
    • Call anyone from anywhere.
  • Camera
    • Take pictures of oneself or your surroundings.
    • All pictures save to the gallery where they can be retrieved with a copyable link.
    • As of v1.0, there is currently two photo modes for front/rear camera.
  • Contacts
    • Add a phone number to your contacts for easier access.
    • Supports up to 19 characters for phone number by default and easily changed within the
    • Gif support for avatar.
    • Quickly call, text, and with additional configuration send money.
  • Notes
    • Something you want to remember in game? Make a note!
  • Calculator
    • Peform calculations.
  • Themes
    • Default dark theme or light theme with other themes in the works. Want to make your own? Follow our documentation.
    • Set within the Settings app.
  • 6 Custom Cases/Frames
    • These cases were made by DayIsKuan
    • Set within the Settings app.
  • Icon Sets
    • Change between material UI icons or our custom made icons.
    • Want to make your own? Follow our documentation.
    • Set within the Settings app.
  • Notifications - Closed
    • While closed, only a portion of it will render to display a notification.
    • As of v1.0, this is currently used for calls, text and tweets.
  • Notifications - Open
    • While open, all notifications occur across the top of the phone.
    • View missed notifications by clicking on the phone's header.
  • Streamer Mode
    • A mode designed for streamers where images are hidden unless clicked.
    • This applies across all apps on the phone.
    • Easily set within the phone's setting app.
  • Settings Configuration
    • Use a slider to set ringtone and notification alert volume.
    • Copy your phone number to clipboard for easy sharing.
    • Configure a chosen ringtone or alert sound.
    • Choose betwen twelve languages as of v1.0.
    • Change frames, icon sets and themes.
    • Adjust Zoom (100% to 70%).
    • Filter notification preferences.
  • Discord Logging

Final words

A special thanks to all the people who have helped out with the translations! You have all been amazing.

Thanks to Ultrahacx for all the artwork and animations seen in the trailer and this post.

npwd's People

Contributors

antond15 avatar antonstjernquist avatar arm-0001 avatar avarianknight avatar backsh00ter avatar bombayv avatar btngaming avatar dayiskuan avatar dependabot[bot] avatar depfu[bot] avatar erik-sn avatar github-actions[bot] avatar glitchoo avatar itschip avatar itztrivial avatar jfrader avatar liamdormon avatar lukealford avatar lukewastakenn avatar matiasfi avatar nuttyshrimp avatar oldarorn avatar patilhas avatar qalle-git avatar rockysouthpaw avatar samshanks1 avatar tasooneasia avatar thelindat avatar tonybynmp4 avatar wowjeeez avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

npwd's Issues

Bug: Tweets are sometimes initalized as null

Describe the bug
Tweets are sometimes null, which crash the entire phone

To Reproduce
** This isn't reliable at all **

  1. First load in go to tweets
  2. Tweets are null
  3. Phone crashes

Expected behavior
Tweets to not be null on first initialization

Needed information (please complete the following information):

  • Server OS: Ubuntu 20.04
  • Server Artifact version: [e.g. 3486] 4000
  • What version of new-phone-who-dis are you running? N/A

npwd:newPlayer / unloadPlayer

Is this issue related to the phone still being in development?
16211156110d8f8ddef248a4fe6df39192fbf427fa

Describe the bug
Trying to add player data via event, since the char system im working on, is not using regular identifiers

tryed TriggerEvent('npwd:newPlayer', {playerId, identifier, firstname, lastname}) and TriggerEvent('npwd:newPlayer', tonumber(playerId), identifier, firstname, lastname)

The screenshot shows none of the values are nil and contains data, but it refuses to work in any way or form

To Reproduce
Trying to send data via trigger for newPlayer event

Bug: Contacts transfer over after unload

Describe the bug
When a character unloads, they don't get an event to 'reset' their contacts, this leads to them keeping their old contacts due to the atom already being populated

Expected behavior
On unload the contacts atom (and other atoms) be reset and re-fetch on next phone open

Bug: user_identifier not populated when sending messages

Developement Issue

Yes

Issue Description

error: Field 'user_identifier' doesn't have a default value
I defaulted that value to see if it magically fixes it and checked the db.
| id | message | user_identifier | conversation_id
| 1 | Hello | | char1:71e008fe139deedc849b862e33c9bcecbf8f959b+char1:d1c9463e8c6c3bfa3b915dce2380b5f04bf61d04 |
so in this case my identifier is being found as char1:d1c9463e8c6c3bfa3b915dce2380b5f04bf61d04 |
the destination identifier is char1:71e008fe139deedc849b862e33c9bcecbf8f959b
but its not putting either in the user_identifier column.

Issue Reproduction

Built from github on debian 10.
1: installed yarn and nodejs from apt using:
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update && apt-get upgrade
curl -fsSL https://deb.nodesource.com/setup_16.x | bash -
apt-get install -y nodejs

2a: cd /root/txData/server/resources
2b: git clone https://github.com/project-error/npwd
2c: cd npwd/
3: yarn
4: yarn build
5: touch .yarn.installed
6: edit config.json for multi chars
7: restarted server and ingame tried to send a message

Evidence

[ script:npwd] [NPWD] [messages] [error]: Failed to send message, Field 'user_identifier' doesn't have a default value
[ script:npwd] [NPWD] [events] [silly]: netPromise > npwd:fetchMessages > RequestObj
[ script:npwd] [NPWD] [events] [silly]: {
[ script:npwd] source: 1,
[ script:npwd] data: {
[ script:npwd] conversationId: 'char1:71e008fe139deedc849b862e33c9bcecbf8f959b+char1:d1c9463e8c6c3bfa3b915dce2380b5f04bf61d04',
[ script:npwd] page: 0
[ script:npwd] }
[ script:npwd] }

Twitter fails to initalize if two players have the same name

Describe the bug
If another player has the same name as you Twitter will fail to initialize for that player
[NPWD] [twitter] [error]: Failed to get or create a profile, Duplicate entry 'Mike_Hunt' for key 'profile_name_UNIQUE'

To Reproduce
Steps to reproduce the behavior:

  1. Have the same name as an already existing Twitter user
  2. Try to load the player
  3. Fail to create a profile

Expected behavior
Twitter to properly initialize when they have the same phone number.

Needed information:

  • Server OS: [e.g. Windows 10] Ubuntu 16.04
  • Server Artifact version: [e.g. 3486] 3922
  • What version of new-phone-who-dis are you running?: HMMM

Bug: Camera does not change back to rear facing mode using up arrow

Describe the bug
When the user tries to switch between rear facing and front facing on the camera the phone just does an animation but stays on front facing mode

To Reproduce
Steps to reproduce the behavior:

  1. Open Phone
  2. Click Camera
  3. Click Add
  4. Press up arrow (it should go to selfie mode)
  5. Click up arrow again and it does not go back to rear facing mode

Expected behavior
It should transition between front facing and rear facing camera on up arrow press

Evidence
https://gyazo.com/c2eb35a25daed00ad9234146730a03a9

Needed information (please complete the following information):

  • Server OS: Windows 10 Server
  • Server Artifact version: 3502
  • What version of new-phone-who-dis are you running?: Version as of 2 hours ago on GitHub

Additional context
N/A

Phone fails to fetch html

Is this issue related to the phone still being in development?
If so, please consult the gitkraken to see if it's already being tracked.
Unsure if this is related to this bug https://app.gitkraken.com/glo/view/card/fc3b54291da048b2a52799c2cc04fc0a

Describe the bug
Every single app throws this error in the client console (this phone is when opening the contacts app) Uncaught (in promise) TypeError: Failed to fetch (2new-phone-who-dis/resources/html/index.html#/phone/contacts:0)

To Reproduce
Steps to reproduce the behavior:
Download NPWD
Follow the docs on install guide
Load in the server and open the phone
Click on any app and the error will throw

Expected behavior
Apps should be working
Current Apps Not Working:

  • Twitter
  • Contacts
  • Calling
  • Texting
  • Notes
  • Ads

Evidence
unknown

Needed information (please complete the following information):

  • Server OS: [e.g. Windows 10]
  • Windows Server 2019
  • Server Artifact version: [e.g. 3486] Don't know? Do version into your server console.
  • 4201
  • What version of new-phone-who-dis are you running?
  • V0.1.3 (also tried V0.1.2 and develop branch)

Additional context

  • NodeJS Version 14.17.3
  • npm Version 6.14.13

Bug: My M1 refuses to work

Developement Issue

No

Issue Description

This issue is a place where I can release my anger regarding docker platform architecture edge cases for FXServer, specifically for the latest Apple Silicon chips. It appears that mono isn't playing nice with ARM64 most likely (but why???????), anyways thanks for attending my Ted talk.

I don't expect CFX to bring M1 support but it would be nice to figure out a way to virtualize on darwin-arm64, so I can actually work on FiveM related things when I am away from my Windows machine.

Issue Reproduction

  1. get m1
  2. spend 8 hours of ur life trying to containerize FXServer + Alpine in docker
  3. fail
  4. repeat

Evidence

This is gonna be closed immediately anyways

Bug: Twitter app error (Kashacters)

Describe the bug
When I try to setup a Twitter account (Profile Name), phone throws an Uncaught TypeError: e.onClick is not a function. Weird thing which I noticed is when I first launched the Twitter app, it opened Twitter homepage(idk exactly what it is, but it seemed like phone was trying to load tweets) but then the Twitter app closed. On relaunching the app, I got the Twitter account setup with Profile Name field

To Reproduce
Steps to reproduce the behavior:

  1. Open phone
  2. Open Twitter app
  3. Enter a username and click the button

Expected behavior
Successful creation of Twitter account was expected

Evidence
https://cdn.discordapp.com/attachments/791854455468458040/808651122465308672/unknown.png
https://cdn.discordapp.com/attachments/791854455468458040/808651178052812800/unknown.png

Needed information (please complete the following information):

  • Server OS: Windows 10
  • Server Artifact version: v1.0.0.2941
  • What version of new-phone-who-dis are you running?: IDK but I fresh built the master branch today (Feb 9,2021)

Enhancement: Billing

Insted of having that pesky esx_billing menu that feels odd and malplaced.

An integrated solution to pay bill's would be a nice thing, maybe as a part of the bank app, where you got a overview of your bills and with a click on a button makes the payment.

Bug: Contacts are based off identifier not number

Developement Issue

Yes

Issue Description

Contacts are fetched based off the identifier since the source phone number isn't stored in the SQL. So with multicharacter, all characters would have the same contacts assuming they have the same identifier.

Issue Reproduction

  1. Create a contact on Character 1
  2. Create a contact Character 2
  3. Ensure NPWD
  4. Ensure your framework or relog or select new character (otherwise contacts will return null for getPhoneNumber)
  5. Upon loading, your contacts will have merged.

Evidence

No response

Bug: Twitter account creation.

Describe the bug
Fresh install, latest "version" - When trying to create a twitter profile, it fails and drops a error in server console
1621566667942d9d20d8db764120a2f0400fb59757

To Reproduce
Use latest version, with multichar enabled, create account and error is droped in console

Bug: Multichar error

Describe the bug
There is an issue with getIdentifier being triggered, even if multichar support is enabled, it still try to call it and drops a error soup in console.

1621566925517c3df1fd39dc753cbd76cc5c105a71

To Reproduce
Using a system where it's not a normal identifier used.

Road to v1.0.0 Release - Where We Are Now

Since we actually are getting close to release, it is time to get a basic checklist of what we want done before v1.0.0, expect this to grow/shrink over the next week

The Checklist

Perf Testing

  • At scale testing with a high number of concurrent players.
  • Profiler data for React Renders, Client Side, & Server Side

Misc

  • Complete and verified translation keys for offered locales
  • Test Linux compatibility and attain a repro for globbing issues, if one exists.

Phone

  • Complete dark theme
  • Complete light theme

Client Side

  • Enable keyboard controls for WASD while retaining mouse focus.

Server Side

  • Public facing exports allowing for certain NPWD internal behavior to be altered by users.
  • Enhanced logging to Sentry and files

Enhancement: Better camera

The camera is very limited currently, you can only take one direction images, gcphones camera module, allows more freedome and ability to zoom, i think this should be looked in to, since this feels like a must have feature, since it makes the phone camera way more versatile.

Bug: Missing SQL table

Is this issue related to the phone still being in development?
If so, please consult the gitkraken to see if it's already being tracked.

Describe the bug
The npwd_bank_transfers table is missing in the import.sql

To Reproduce
Steps to reproduce the behavior:

  1. Load into the server and open phone

Expected behavior
Table should exist

Evidence
When opening the phone you're met with this error in the server side console [NPWD] [bank] [error]: Failed to fetch transactions, Table 'es_extended.npwd_bank_transfers' doesn't exist. After looking into the import.sql file provided there is no statement that creates this table

Needed information (please complete the following information):

  • Server OS: Windows 10 Server
  • Server Artifact version: 3534
  • What version of new-phone-who-dis are you running?: Newest fork

Additional context
N/A

Bug: Call animations triggers for recievingSource before responding

Developement Issue

No

Issue Description

Upon calling, the target player will play the animation as if the call has started despite nether being in a call or having accepted/denied a call.

Issue Reproduction

  1. Open phone and navigate to dialer
  2. Call a player who is online
  3. Upon receiving the call notification, the targetPlayer (person being called) will play a calling animation.

Evidence

chrome_HfFyV1Eac7

Bug: Updating Note title creates a new note after restarting the resources

Describe the bug
Updating Note title creates a new note after restarting the resources

To Reproduce
Steps to reproduce the behavior:

  1. Create or take a already existing note.
  2. Update it with a new title
  3. Restart 'npwd'

Expected behavior
To just update the db with the title.

Needed information (please complete the following information):

  • Windows 10
  • 4435
  • Develop branch (8/28/21)

Enhancement: Mobilepay/Applepay/GooglePay

Not sure if the bank app can do this, but it could be a part of it.

Here in Denmark where im from we got something called MobilePay, it's an app where we can transfer money to friends, companys and what not, even request a payment.

A simple version of this could be nice, where you transfer based on phone number.

Found a video https://www.youtube.com/watch?v=Z6ho7u0sei4 - it's very danish but it showcases the idea.

Bug: Phone freezes when players text each other

Is this issue related to the phone still being in development?
If so, please consult the gitkraken to see if it's already being tracked.

Describe the bug
When a player texts another player regardless if they're in their contacts or not the phone will freeze for both the sender and receiver when they go to open the message

To Reproduce
Steps to reproduce the behavior:

  1. Player1 sends a text message to Player2
  2. Player2 opens messaging and tries to press the unread message
  3. Player2's phone bricks (ui is left on the screen but player can still do the phone animation with F1)
  4. Shortly after Player1's phone also bricks

Expected behavior
Texting players should not brick phone

Evidence
Here is the output of devtools when the phone freezes
e9ac275e8a40310cfa1ff647bb1df105

Here is a video of the issue occurring
https://user-images.githubusercontent.com/32118783/127502293-5b87773c-f3c9-40bc-80c5-952708ba0dea.mp4

Needed information (please complete the following information):

  • Server OS: [e.g. Windows 10]
  • Windows Server 2019
  • Server Artifact version: [e.g. 3486] Don't know? Do version into your server console.
  • 4260
  • What version of new-phone-who-dis are you running?
  • Develop branch

[VRP] Call target cant accept/reject call

Developement Issue

Unsure

Issue Description

Cant accept or reject phone call, got error cannot set prop is_acepted of undefined but in database the row are ok.

Issue Reproduction

Make a call to another player online.

Evidence

unknown
unknown (1)

Bug: Bad argument format

Is this issue related to the phone still being in development?
If so, please consult the gitkraken to see if it's already being tracked.

Describe the bug
Compilation error due to bad argument format

To Reproduce
Steps to reproduce the behavior:

  1. Run 'yarn build' on linux
  2. See error

Expected behavior
A successful compilation

Evidence
/server-data/resources/npwd/phone/src/common/utils/getLocationFromUrl.ts(4,41):
Argument of type 'String' is not assignable to parameter of type 'string'.
'string' is a primitive, but 'String' is a wrapper object. Prefer using 'string' when possible. TS2345

2 | 
3 | export const getLocationFromUrl = (url: String) => {

4 | const { pathname, search } = parseUrl(url);
| ^
5 | const searchStr = '?' + (search || '');
6 | return { pathname, search: searchStr };
7 | };

Needed information (please complete the following information):

  • Server OS: Debian 10
  • Server Artifact version: 4126
  • What version of new-phone-who-dis are you running? LASTEST

Additional context
To correct this problem you need to replace: String by string at line 3 of getLocationFromUrl.ts file and run yarn build.

Bug: Contacts loading

Describe the bug
Contacts might not load as intended.

Have had this issue once, ill try and confirm it and reproduce, but looks like and issue maybe multichar related?

Where contacts dos not load before adding a new contact.

Enhancement: Add Public Facing Identifier API

Is your feature request related to a problem or design oversight? If so, please explain it.
Yes, currently the identifier attribute for NPWD players is readonly and assigned on join. This excludes individuals who use a multicharacter system from easily changing a players identifier.

What is your suggestion?
Implement a public API through an export that allows for users to set the player identifier and any other relevant in-memory data used in the phone. These would be triggered whenever a framework loads a player, or unloads a player.

Any additional comments or concerns?
Exact implementation details should be discussed.

Bug: (App: Dialer) Unable to dial a number due to a bug with dash.

Describe the Bug

  • You cant dial anyone because the - results in the entry being cleared.
  • If you type the dash with the keyboard, the call can't be made.

image

Steps to reproduce

  • Open phone
  • Go to phone app and dialer
  • Click any number and press -.

Entry is cleared and an error shows in the console.

Same can be done with the keyboard except the dash will prevent the call from being made.

Caused by:
d95cd8d
Reverting this fixes the issue.

Enhancement: Job Listing App

Listing of available "non-whitelisted" jobs from a Job Listing App would be great. Would be great to no longer have to have some random location or "Job Center" to go to to join a job when you could on the fly join a job from your phone. A long with joining a job obviously the ability to change or leave job should be in this as well. As far as a config should go make it easy to simply add the job name from job table(ex. taxi, fishing, garbage, burgershot, etc...)

Bug: Shift Clicking the link tags changes the NUI root.

Describe the bug
When you shift clicked a button in the UI everything disappears. After checking out the web code I saw that you guys were using links to navigate with react router and therefor used links to open apps in the main menu. Normally in the web browser, when you shift click a link, it would open that page in a new window, but since the FiveM NUI doesn't handle multiple windows, it will just navigate and change the root html to the page you clicked on.

To Reproduce
First problem:

  1. Open Phone
  2. Start running
  3. Click on any of the apps on the home screen.

Expected behavior
The phone opens the app or does the action the button(link) should've done.

Evidence
Video:
https://user-images.githubusercontent.com/19311856/120891442-fe18ac80-c608-11eb-8a29-9ecebcec5735.mp4

NUI devtools Sources Tab:
image

NUI devtools Elements Tab:
image

Needed information (please complete the following information):

  • Server OS: Windows Server 2019 and Windows 10
  • Server Artifact version: 4007
  • the newest version on the master branch after @itschip merged this pr yesterday.

Bug: Failing to compile (Typescript error)

Creating an optimized production build...
=============

WARNING: You are currently running a version of TypeScript which is not officially supported by @typescript-eslint/typescript-estree.

You may find that it works just fine, or you may not.

SUPPORTED TYPESCRIPT VERSIONS: >=3.3.1 <4.3.0

YOUR TYPESCRIPT VERSION: 4.3.5

Please only submit bug reports when using the officially supported version.

=============
Failed to compile.

C:/GServers/GTA5M/[ESX][DEV]NightOwls/server-data/resources/[standalone]/new-phone-who-dis/phone/src/common/utils/getLocationFromUrl.ts
TypeScript error in C:/GServers/GTA5M/[ESX][DEV]NightOwls/server-data/resources/[standalone]/new-phone-who-dis/phone/src/common/utils/getLocationFromUrl.ts(4,41):
Argument of type 'String' is not assignable to parameter of type 'string'.
  'string' is a primitive, but 'String' is a wrapper object. Prefer using 'string' when possible.  TS2345

    2 |
    3 | export const getLocationFromUrl = (url: String) => {
  > 4 |   const { pathname, search } = parseUrl(url);
      |                                         ^
    5 |   const searchStr = '?' + (search || '');
    6 |   return { pathname, search: searchStr };
    7 | };


error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Bug: Notes FAB does not open NoteModal (develop)

Is this issue related to the phone still being in development?
If so, please consult the gitkraken to see if it's already being tracked.

Describe the bug
Note FAB does not open modal. Probably related to newly added exports.

To Reproduce
Steps to reproduce the behavior:
Click on the FAB

Expected behavior
A clear and concise description of what you expected to happen.

Evidence
See for image

Needed information (please complete the following information):

  • Windows 10
  • S4435
  • Develop branch (8/28/21)

Enhancement: Add data validation to restrict field length when adding contacts to avoid errors.

Is your feature request related to a problem or design oversight? If so, please explain it.
Yes

What is your suggestion?
Restrict the name and number field when adding a new contact to 60/10 characters respectively as this is the current length for the SQL.

Any additional comments or concerns?
Currently this results in errors within the server console as such:
image
image

It's not really "breaking" as the phone behaves correctly, it just makes sense to avoid the issue all together.

Bug: Sending message to offline player causes the phone UI to brick and not work at all

Is this issue related to the phone still being in development?
Yes

Describe the bug
If you send a message to a player thats offline (in my case a contact), it will send a error message, but still 'send' the message. When re-entering the message app and trying to open the conversation again, the phone UI completely bricks, and you need to relog for it to work again. In the Dev Tools console it says:
"POST https://npwd/npwd:app:MESSAGES" 404 (Not Found)

To Reproduce
Steps to reproduce the behavior:

  1. Go to the message app
  2. Send a message to a offline player
  3. Exit the message app
  4. Re-enter the message app, and try to open the conversation with the offline player again

Expected behavior
The phone UI should brick and you won't be able to use the phone, and need to relog

Evidence
Just picture the phone being stuck on the screen and nothing else to do

Needed information (please complete the following information):

  • Server OS: Windows 10
  • Server Artifact version: 4007
  • What version of new-phone-who-dis are you running? Latest master

Additional context

Bug: While using text fields, controls are enabled so movement occurs/menus open.

Describe the bug

  • If a server has any menu bound to any key that is typically used when writing a message (A-Z, commas, periods, ect) then that menu will pop up.
  • People will move slightly every time they type the letters W,A,S,D as we do not freeze them now.

The only solution I have would be to disable all control actions if they're clicking on a text field or SetNuiFocusKeepInput(false) within text boxes.

Issue was introduced in the following PR: #212

Bug(Calling): Offline players/invalid numbers are currently not handled when calling

Developement Issue

Yes

Phone Version

Develop

Issue Description

When calling a player who is offline, the call fails and a server console error is shown.

Issue Reproduction

  • Open Dailer
  • Call number who is offline

Receive error

Evidence

image

image

Suggested work around

Simply send a different error to the UI when source isn't found that the player is currently outside of the service area.

Refactor the console print stating player is offline.

Enhancement: Twitter refactor

Refactor twitter to use promise format. Twitter is very unoptimized and we have to decrease the amount of data we fetch, amongst other things listed below.

Priority:

  • Limit tweets we fetch
  • Introduce pagination / infinite scroll for tweet list (prevent information overload and less data to be transferred)
  • Fix options for twitter such as 'allowEditableProfileName' which is very broken.
  • Use correct notification setting

Maybe:

  • Handle mentions and replies better

Bug: Call doesn't end for both participants

Developement Issue

Yes

Issue Description

Calls doesnt working correctly on vrp base.

When player end the current call a promisse event npwd:endCall got status ok and user1 phone disconnected call, but the user2 continue call and when him click on endcall get error, the call doesnt exist anymore.

Issue Reproduction

  1. Login in 2 users
  2. Make a call
  3. End call
    $. Who clicked will got success and disconnect call, but other contact doesnt update call status

Evidence

unknown (2)

Bug: Match Making has no Input Validation on client

Describe the bug
Players are able to input any value into matchmaking input fields and send it to the server

To Reproduce
Steps to reproduce the behavior:

  1. Setup your profile
  2. Add some stupid long job name
  3. Errors in MySQL instead of client

Expected behavior
Client to get a error and not send to server

Evidence
error

Bug: Phone's NUI Freezes and requires relog.

Describe the bug
Essentially what occurs is the phone becomes unresponsive and remains stuck on on your screen, You can ensure the resource, do phone or even phone:restart and the UI isn't removed. A full relog is required to remove the phone from the screen.

To Reproduce
Still need a reproduction for this issue as I can not find a viable one. It occurred previously in dev but i haven't since been able to reproduce it until today where it occurred on 3 occasions to myself and also occurred with others who were testing the phone too. The only constant is related to tabbing out and tabbing back in.

The issue has occurred on multiple apps so it isn't app restricted. I also reproduced it on a non esx server as well.

Evidence
If applicable, add a screenshot or a video to help explain your problem.
image

Screenshot doesn't really help as there is no error logs. Though you can see in the console the resource was restarted and the issue still stayed.

Needed information (please complete the following information):

  • Server OS: Windows 10
  • Server Artifact version: 3759
  • What version of new-phone-who-dis are you running? 9896f2384e18108c8d90ef4ae70d35141f7a5dd9

Additional context
A valid reproduction still needs to be found. It's probably something we should fix before v1 is released.

Enhancement: Adjust messages SQL to remove unnecessary table.

Is your feature request related to a problem or design oversight? If so, please explain it.
Design oversight. We currently have a table for message labels npwd_messages_labels (only used for group messages) while also having the same column within npwd_messages_groups

What is your suggestion?
Use the already existing column within npwd_messages_groups instead of creating another table to handle it.

Additional Information?
Currently the label column is unused in this table. See below:

CREATE TABLE IF NOT EXISTS `npwd_messages_groups` (
  `id` int NOT NULL AUTO_INCREMENT,
  `user_identifier` varchar(48) NOT NULL,
  `createdAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updatedAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  `group_id` varchar(512) NOT NULL,
  `participant_identifier` varchar(48) NOT NULL,
  `label` varchar(60) DEFAULT '',
  `unreadCount` int(11) NOT NULL DEFAULT 0,
  PRIMARY KEY (`id`)
);

As you can see, label already exist in this column but as stated previously; it Isn’t used. The phone currently uses the table below for it:

CREATE TABLE IF NOT EXISTS `npwd_messages_labels` (
  `id` int NOT NULL AUTO_INCREMENT,
  `user_identifier` varchar(48) NOT NULL,
  `label` varchar(60) NOT NULL,
  `createdAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updatedAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  `group_id` varchar(512) NOT NULL,
  PRIMARY KEY (`id`)
);

BUG: Animations Reset

Describe the bug
Animations reset when doing any action

To Reproduce
Steps to reproduce the behavior:

  1. Start a phone call
  2. Close the phone
  3. Animation goes away with the phone

Expected behavior
Animations to continue to play when in a phone call

Bug: Twitter doesn't use the right notification volume

Describe the bug
Twitter notifications are done based on "notification volume" instead of "Twitter notification volume"

To Reproduce
Steps to reproduce the behavior:

  1. Tweet and listen to it on another client
  2. your ears bleed
  3. suffer

Expected behavior
Twitter notification volume to be used for Twitter notifications

Enhancement: Allow for Config to be edited without rebuild

Is your feature request related to a problem or design oversight? If so, please explain it.
Design oversight

What is your suggestion?
To allow for the config to be edited only requiring a resource restart & not a total rebuild of the phone

Any additional comments or concerns?

This can be done by either using a dynamic require, which imports the config.json at runtime or by using the native LoadResourceFile to also dynamically load at runtime.

Bug: Eager NUI Requests are Invalid on Mount

Developement Issue

No

Issue Description

Fetching on the client side when using an async selector immediately occurs whenever a component is mounted that requires the scoped data. This creates a problem of eager fetching, as certain apps may immediately trigger a server side fetch upon NUI load before the player has been added to the server maps.

To fix this, we must prevent requests from going out until we can confirm that the player source has been processed and exists within the server side player maps. At this point, it is considered safe to initialize server requests.

Issue Reproduction

N/A

Evidence

No response

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.