#programming
1 messages ยท Page 23 of 1
so when someone applies i will reply and send a code or something which they will have to send in the built in application where i will accept
Do whatever works for you ๐
np ๐
https://laracasts.com/series/laravel-6-from-scratch
@unkempt hamlet Well, yes, but actually no. Most of those episodes are short. In terms of the content, it is similar to previous series. The newer ones just have more frontend stuff
I watched this serie and it was pretty good... 6 hours and 32 minutes. When I checked the version 6, there were not many changes, just more stuff about frontend
But in general, I think it is the best series for starting with Laravel
Indeed
So would you recommend using the learn laravel 6 from scratch then take a look at whats new in laravel 7?
Since there isn't a series for Laravel 7 from scratch
Laravel has a new versioning scheme, so 6 vs 7 is not like 4 vs 5.
Ok so there isn't much difference?
Pretty much.
Ok cool thanks
Using Laravel requests can you get post data by input type e.g retrieving all POST data that is a checkbox?
That is not even possible as the browser does not send input types
Worth a try but I think I've found a different solution
@quartz moth set names as "chk_XXX" and loop all inputs, if starts with chk is a checkbox ๐ be aware not selected checkboxes are not sent in POST
Oo thanks for that I'm gonna try that
Soon... ๐
myBB 
someone has a working example using a bootstrap 4 datetimepicker with webpack on laravel and mix?
To all members, who are using *unix - OS' -> Which one can you recommend me for my "old" laptop? Currently is Win 7 Pro x64 Installed, but I want to change to Linux. I am known in Linux as headless Server (Debian 9) - now I want to try it out as real useable OS.
TIA^ Maurice B.
Ubuntu or Linux Mint Cinnamon I'd say
Ubuntu / Debian are likely the same.
Hiya,
I have the following code (PHP, using Laravel) ```
try {
$IsUserBanned = $guild->guild->getGuildBan([
'guild.id' => (int)0,
'user.id' => (int)$discord->id
]);
} catch (\GuzzleHttp\Exception\ConnectException $e) {
//Catch the guzzle connection errors over here.These errors are something
// like the connection failed or some other network error
$response = json_encode((string)$e->getResponse()->getBody());
dd("test");
}
This returns a 404, which is expected, but Laravel doesn't seem to catch this. I expect the
```dd("test")```
to be executed but it isn't and I get the error in the attached picture.
Does anyone have any ideas why it's not catching please? ๐
Thanks, tried that with use GuzzleHttp\Exception\ClientException; at the top but no joy sadly
And repacing the catch with \GuzzleHttp\Exception\ConnectException with ClientException obvs
You can use RequestException if you don't care about the exact error.
Someone just fixed it on the Laravel Discord, it needed to be CommandClientException ๐
But thanks CJ ๐

To all members, who are using *unix - OS' -> Which one can you recommend me for my "old" laptop? Currently is Win 7 Pro x64 Installed, but I want to change to Linux. I am known in Linux as headless Server (Debian 9) - now I want to try it out as real useable OS.
TIA^ Maurice B.
@shadow marsh it heavily depends how much you want to customize stuff, and how much experience you have with Linux.
For a beginner, as Nathan mentioned, I would recommend Ubuntu or Mint.
Okay ^^ thanks :3 - well, I am working now over 2 years with Linux Debian 8 & 9 (headless, SSH) and as my Laptop is too good for threwing away - I want to use there Linux. No games will run except Minecraft. Programs like Discord, Google Chrome, LibreOffice are a good thing to run there :3
Heyho - Now I am writing over Ubuntu 18.04.4 :3 Didn't know, that this laptop is that fast
Thanks for ur help, Shawny & Nathan 
Anyone good at angularjs?
Not really, I'm looking for someone I can pay to do some backend work for me
https://www.upwork.com/search/profiles/?nbs=1&q=AngularJS There you go ๐
success
๐
When you open your new website for Alpha testing ๐
Lmao
lol
Hmm. Set up a work queue, or do small background jobs like sending emails and whatnot by throwing them into coroutines in the main webapp
It depends.
Ye, I am just trying to decide for this specific project x3
Main thing is trying to predict what kind of background jobs I might do in the future, whether I'll be running heavier jobs later on
Are the emails time-sensitive?
If it's things like newsletters, maybe setup a cron job to send them out over time?
Transactional somewhat time sensitive to begin with, maybe things like notifications later
Gonna be running a separate cron process anyway, for that matter, so that I can easily scale out to multiple boxes without having the cron functions run multiple times
Tbh, a decent portion of this decision taking any time is my tendency to overthink it, trying to think too much ahead
Throwing most emails into coroutines would be fine for most of it. For mass emails later on, I can easily just use a coroutine to make batches, and let a cron job do the actual sending of that
๐
mail send could fail and this throw an exception to UI or lose the email send. It's better to send them in a service bus, having a service listening on the service bus, taking the message and do what it have to do. Putting on a service bus only for emails, opens to a lof of other opportunities
Mhm :p
Nearly at beta stage of my new site now, looking forward to sharing with you all for testing ๐
Sadly not but I should register that ๐
It is occupied already
@mossy cloud I'd be happy to help test. Just drop me a DM if you want me ๐
Will do, ta :3
I would help you as well, Penguin
just DM me, if u'r ready :3
We'll be in open beta soon, dw ๐
"dw" means what exactly? ๐
dw = don't worry ๐
Caddy 2 is amazing https://caddyserver.com/
so simple to configure and securely encrypted by default
noot.net is registered since August 1999 ๐ wow
tbh a webserver in go sounds interesting... but an all in one solution can never be that good...
no good admin would realise a WAF in his Web Server directly... caching... has to be an allround function, so no specialisation possible most users would deactivate it to use what they need... varnish/ES/redis etc
but as a reverse proxy it could be quite interesting
the reverse proxy with load balancing could rly be interesting... thats what i gonna check out at least ๐
it's highly modular
TruckyBot has been verified!
Congrats ^^
Wooo well done
Mine as well 
What bot do you develop @shy swan ?
Last year, I made a bot for small servers with basic music, meme and moderation functions. It was in a some servers but then I shut it down 
Sad to hear.. but why did you shut it down?
I started it two weeks ago to get verified
I might rework some things.
Oi nice ๐
I didn't want to invest more time in the bot because ยฏ_(ใ)_/ยฏ
I also need to recode my bot.. but this time in JS instead of Java...
That's cool though ๐
Java 
It's the only known Language ๐
Now I just miss
,
and

and I can code only Java... because Minecraft and so on #
cough
You're not knowing true pain until you use PHP for it xD

But honestly it works so well ^ Just discord login and use Discord for Nootifications
๐
Before we had to check a flag for VTC drivers to say they're drivers yea
Now it's just an automatic laravel gate, if they have the VTC Driver role in Discord, it'll show for them
Makes our lives so much easier for VTC Management

I know this also xD
The same on my report system xD Databasespam and Botspam xD (reports are saved in DB + will sent by Bot in Discord)
๐
cough https://prnt.sc/s7z0ip
Hope your sanitising those URL query tags ๐
well, the webdev has left us... so we may do this in another way... or kick it completely out
the new Webdev is currently LOA (due to an good reason)

also... I don't know, why he wanted this URL... uuid of both players are saved in DB...
#stupiddev 
I do not think it is bad to use PHP for the bot, tho
We also use a bit of PHP for @glass rampart due to Guest/User role

Well, I want to convert the default bot from us from Java to JS
but the thingy is... I don't really understand JS 
If it works, it works.
It doesn't do anything anymore... due to the recent changes...
You can always use a webhook
Also... a good Discord Bot is written in JS, not?
Good is if it works well, not what it's coded in ๐
Good Discord Bot is written on the language you're comfortable enough.
JDA?
Java Discord Wrapper :3
0_o
I just know Java... thats it
But I even don't understand PHP... or HTML... or JS or whatever 

All you need 
English 
CJ 
I am not wrong though
Never stated it that you are wrong tho ๐
me in person dont cares which languages my devs are using as long as it is working and others can understand / read their code. i like php and python but my main dev loves JS ^^
...and everyone hates ExtJS ๐
It's JS ๐
Well, kinda. It's made with a software which uses JS but I created modifications for it to keep it up to date 
Very conditional code 
Nah.
?
It is not so much conditional 
I feel with you, Penguin 
Global site performance profiling results for https://truckersmp.com.

Wooo! Finally hit Public Beta ๐
https://plasmagc.com/ - Please tell me what you think, any suggestions or improvements I'd love to hear them ๐
Don't attack it then 
It's Cloudflare, I'll take a look as what's blocking that
@unkempt hamlet Can you try again please?
Think it was our Geoblocking
Thankss ๐

Thanks :)
Minimalistic, but looks nice ๐
Thanks.
Hello all : )
If any of you know how to build job loggers for VTCs and would like to work with a VTC please do me a favour and send me a message : )
Kinda ๐
time to get this show on the road
cheers
tf is wrong now
-=
:;
oh thank you
you may want to start from basics of javascript before jumping into an extensive library
im watching off youtube
What error do you get? @ember canyon
Your SSL certificate expired mate
Hm.
You using LetsEncrypt?
Yes
It's done. Thanks
np, still showing invalid for me, make sure you restart your web server
That I can't really help you with, just check what the antivirus is picking up on to see why it's triggering it
I have done the backup, restarted apache
And now server restart
Now Err 521
Again
521 is web server down
so in SSH do sudo service apache2 status
And it should tell you why it didn't start
Loaded: loaded (/lib/systemd/system/apache2.service; disabled; vendor preset:
Active: inactive (dead)
Loaded: loaded (/lib/systemd/system/apache2.service; disabled; vendor preset: enabled)
Active: active (running) since Sat 2020-05-02 13:29:05 CEST; 49s ago
Process: 774 ExecReload=/usr/sbin/apachectl graceful (code=exited, status=0/SUCCESS)
Process: 725 ExecStart=/usr/sbin/apachectl start (code=exited, status=0/SUCCESS)
Main PID: 736 (apache2)
Tasks: 6 (limit: 9830)
CGroup: /system.slice/apache2.service
โโ736 /usr/sbin/apache2 -k start
โโ778 /usr/sbin/apache2 -k start
โโ779 /usr/sbin/apache2 -k start
โโ780 /usr/sbin/apache2 -k start
โโ781 /usr/sbin/apache2 -k start
โโ782 /usr/sbin/apache2 -k start
mai 02 13:29:04 bot systemd[1]: Starting The Apache HTTP Server...
mai 02 13:29:05 bot systemd[1]: Started The Apache HTTP Server.
mai 02 13:29:53 bot systemd[1]: Reloading The Apache HTTP Server.
mai 02 13:29:53 bot systemd[1]: Reloaded The Apache HTTP Server.
Then
Here we are
@mossy cloud Thanks.
Hmm, seems to be running
Still
I don't know then, sorry :/
You're running your web server from your computer?
Nope
@mossy cloud Thanks. it's done.
np โค๏ธ
I had some Cert for multilanguage
So, it was checking for an another Cert
and it seem to loop
So I deleted the old cert and remanaged the apache2.conf file
Yikes... I have issue with mariadb-server... ๐
I've installed correctly with apt on my WSL Gen2 Ubuntu 20.04, but I forgot that I should run normally mysql_secure_installation instead of going with sudo...
And now I have no idea what to do, MariaDB doesn't even start right now...
Maybe I've crashed it so hard... ๐ฆ
Just remove WSL instance and install it again))
Just remove WSL instance and install it again))
Will have to, I guess...
Meh... It's time to import again
you could just apt purge mariadb
I think the exact command would be apt purge mariadb-server && apt autoremove --purge
might also need to remove anything left over in the data folders under /var
Don't worry - sorted out.
Decided to reimport the build.
I purged earlier mariadb and removed some stuff, but I think that I removed some needed files so then it couldn't load in xd
Exception thrown: 'Newtonsoft.Json.JsonReaderException' in Newtonsoft.Json.dll
An exception of type 'Newtonsoft.Json.JsonReaderException' occurred in Newtonsoft.Json.dll but was not handled in user code
Additional text encountered after finished reading JSON content: 3. Path '', line 2, position 0.
any suggestion? ETCars .Net SDK
What is the text you're trying to read?
I'm trying to read etcars telemtry data
Check the text you're actually receiving.
yeah i saw that and thats a real object but the fact is i'm getting somethink like that
"data": {
"status": "TELEMETRY",
"telemetry": {...}```
what is this -> 17306
@sage rose https://github.com/shardick/etcars-dotnet-sdk this is an old project, not totally mantained but there is some pull request and issue sent, but it should work
etcars doesnt send data completely coherent
๐ค
because data are splitted in one than packet and you have to "build" it
All data broadcast is in a JSON format with 1 exception. The string broadcast starts with an 8 character header that represents the length of the string broadcast.
yes, it's not always a full json string
but need to be merged with next packets until the end of the string or next initial bit
ETCARS is an old sdk which doesn't support the newest features that the current telementy by SCS Software provides. It may give you some data, although it might be incorrect as it's being old sdk. Additionally the telementy send the data by socket (localhost) in a raw format.
This is kind of messed up the link for spring mod on tmp website can maybe download adware on ur system if you dont have a antivirus program like i do here
@willow beacon Thats just sharemods, not TMPs fault.
Its how they do their advertising
Kaspersky Good antivirus
Yes
All right - it's time to dive into Laravel. :3
Azure is ready, I hope it'll work from the very beginning. ๐
In the mean time maybe finally I'll finish site for my script so I can publish in Unofficial tools...
You can setup Laravel on your PC first to do dev work locally
homestead
laragon ๐
Hm... Idk, if I have my WSL with LAMP ready to program, is necessary to setup Laravel Homestead.
Or am I wrong? ๐ค
Microsoft implementing Visual Studio Code into GitHub 
So Virtualbox or Hyper-V.
WSL 2 is using Hyper-V emulation
Not quite
I mean, not like a standard virtual machine.
I am using Homestead (Hyper-V) for TruckersMP development.
WSL is the (emulated) Linux environment. Why would you need to install emulator in emulation?
you don't need anything Windows specific when working inside WSL2
All right - I'll move back to what I wanted to do that is to download dependencies with use of composer.
and then start to dev :3
I've tried to use WSL for PHP environment and I wasn't satisfied.
Node.js is fine
Well - I have some extensions that help me (Intellisense and Extension Pack by Felix Becker).
When I'll have ability to dev on my personal VPS in home, I'll dive into other languages.
Right now I limit myself to C++ and PHP
WSL and WSL2 are very different
All right - it's working, now I can get to work :3
Do you have any good courses how to dev in Laravel? ๐ค
Laravel from Scratch
there's laradock for running a dev environment via docker too
@strong quail https://laracasts.com/series/laravel-6-from-scratch ๐
Ye thats helped me ngl
Thx guys. โค๏ธ
@unkempt hamlet tmp API having troubles?
Not now
What's the error?
don't know exactly, http call fails
and now I'm trapping it returning 0 servers as temporary fix
but as neither friends list is not working I think also player API is not responding correctly
I've done some fix from my machine and it worked, but from server seems having some problem. do you banned me? :D
Are you using node-fetch btw?
Do you have a cache for user requests? Do you fetch staff profiles in batch?
i have cache for all, no I don't get batch
Do you fetch Discord accounts as well?
There are certain moments when you fetch +100500 profiles in one second
you know.. with 36 millions API requests per months..it could happen :D
Not in bursts
Do you have rate limiting on your API?
no
but it's check daily and I've no strange traffic when I have it, ban from cf directly
Check 07/May/2020:17:13
so you banned me? :D
yes you are right someone tried to get profiles trough trucky
Please add reasonable rate limiting as soon as possible.
next time please notify me
How they can know that this IP is yours :d
I could add a User Agent in http calls
That's gonna be great.
it's good practice to set your backend user-agent to point to your service
psst
User-Agent: <product> / <product-version> <comment>
i havent a version ๐
httpRequest.DefaultRequestHeaders.UserAgent.ParseAdd("Ohbot/" + CurrentVersion + " (+http://ohbot.3v.fi)");
is what I use for ohbot for example
'User-Agent': 'modchecker/1.1 (+https://twitchstuff.3v.fi/)',
in a thingy without a real version
(I just hardcoded something)
why (+url) ?
gives a canonical point of contact
although really I just did it because it's the way Googlebot's is 
Hm... Actually - if my script calls to main API from TMP, it calls User-Agent of the user's browser, am I correct?
From the browser - yes
if it's the browser of the user making the request, yes
If so, then 

but then it won't be your IP either ๐
Referrer 
Soon @ Issues @ arusf2011/tachograph
Halp mi, i have been banned from API

Soon @ Issues @ arusf2011/tachograph
@strong quail well, if you properly cache your data and do not send multiple requests, you should not face such issues
such a nice extension
psst IndexedDB
@unkempt hamlet btw i could have said a lie.. because those calls wasnt to tmp but only to mine.. it's an api doesnt rely on you
redis is nice
is great not only nice
(at)me well, if you properly cache your data and do not send multiple requests, you should not face such issues
In my case, I don't cache.
I call thrufile_get_contents()function and thenjson_decode()on server itself.
We use Redis for storing users 
If I understand you :/
Wow
long term storign users?
Please take some time to have a cache.
If you use PHP, I recommend you this library: https://github.com/TruckersMP/API-Client
PHp ftw
file_get_contents for http requests 
I did that thing in my v2 of Helper, 3v... Didn't thought about using Guzzle
someone from an aws machine is trying to scraping who is online
That's why rate limiting exists
every 15 seconds
dammit 
file_get_contents for http requests (some emoticon)
Yeah - I'm from the oldish school.
@unkempt hamlet i rely on people good sense ๐
lacks error handling and any kind of header processing
As I said, if you use PHP and fetch data from our API, there is not a single reason not to use our library 
If you use PHP, I recommend you this library: https://github.com/TruckersMP/API-Client
Will try it, will see.
I'll add to my project 'till June.
And add caching, too, please
Will need to add some code in order to manipulate it, maybe some class
What is the error handling?
@file_get_contents($url)
Will need to add some code in order to manipulate it, maybe some class
@strong quail there is also useful wiki: https://github.com/TruckersMP/API-Client/wiki
3 years ago 
(at)me there is also useful wiki: https://github.com/TruckersMP/API-Client/wiki
Will check it, don't worry :3
As for now I'll dive back into studying Laravel
@unkempt hamlet user agent added
and which is good as rate limiting? tmp api doesnt expose particular headers in response
ye i know, i have to inspect logs to understand normal usage which rate limiting could hit
I mean, realistically, 60 requests from one session is enough
60 request per second?
Minute


shit happens

Hello, is it possible to show a tracker's rich presence over TMP's one without having to disable TMP's rich presence?
@sick anvil no
oh wow...
Hey guys, looking for some advice please, I've got a Laravel Socialite login with Discord on my site, but I'd like for it to be that the user is redirected back to whatever page they clicked the login button from after a successful login. I can't find what I'm looking for on Google, is anyone able to point me in the right direction?
@mossy cloud I've achieved this setting a temporary cookie before going to diiscord
Do you have any example code you could share please? ๐
Socialite::driver($provider)
->with(['redirect_uri' => "YOUR_NEW_URL"])
Yeah I know that one, but it's setting that URL to whatever the user was last on ๐
You can use url()->previous() for it afaik
Or save it to the cookie as downmeister suggested
I'll give it a go, but I have a feeling that'll kick the user back to the discord login
I'll give it a go, thanks
it's quite simple, store a cookie before going to discord when come back, check if cookie exists, redirect to the cookie value
like arriving to login page with ?redirecturl=xxx and login page saves the cookie if returnurl parameter exists
it's not a good solution tho, but it works :D
Meh... Best error for today...
After moving databases to new MariaDB - Table 'some_name' is read-only... 
Don't worry - I have workbench, will deal with it like that ๐
@mossy cloud Name suggestion for that emote: ":blobguinheart:" ๐
Neat :p
It's good the redirect got done, my biggest pet peeve with ETS2C is after you sign-in, you have to find the event again xD
After having two commands for a ingame-reportsystem - I decided to rework the system.
The system checks, if the given user is online or not and it will be saved in the database + discord
View discord here: https://prnt.sc/sdpcvx
View database here: https://prnt.sc/sdpdsh
What do YOU think about it? (and yes, it's about minecraft x3 )
And also, I know, that "Hey + admin.getAsMention() + etc. -> I've done this as I don't want to ping my admins useless for testing xD
I like it ๐
does anyone know if the open source botranktir discord bot requires a database to connect to?
cuz i dont have a database lol
it requires a mysql database
it doesn't require much from it, so you can run one on the same server with the bot very easily
Yeah lol. I got one but now im having issues implementing it into my existing bot
Hey Devs, can someone answer a weird question for me? I know 1.37 was released about 3 days ago from ETS2 and more than a week for ATS. Why was there a hotfix for MP posted Wednesday, but not a full conversion for 1.37?
This is not a chat to talk to developers of TruckersMP ๐
Shh, i read it wrong OK!?
How does the verification for the server work
Where you must link your discord account to access all channels and I was thinking about doing in a server if it's possible
It uses OAuth2 then a bot to give a role to users who added their account
Can I make the same system from this server work in another server?
Yes, I have done for my server. You need an understanding of basic OAuth2 though
Could you help me do it?@mossy cloud
Np thx
For those of you who use our PHP API client package, we've just released v1.1.0 https://github.com/TruckersMP/API-Client/releases/tag/v1.1.0
If im gonna build up a website from scratch, which "platform" would then be best to start out on?
What are your skills?
0
Learn HTML first
I think html and css would be a good starting point imo because it teaches you how to do all the front end @toxic turtle
Also JavaScript
If you can master all those then it becomes relatively easy to make what you want
If you learn those to a basic level then I'd recommend using frameworks such a bootstrap and jQuery as they massively speed up developing
Finally if you aren't familiar already, start using GitHub for your projects as it is really useful to keep track of code etc
Hmm, well my level about html/php is decent, usually just using google when i get stuck on my line
Is GitHub also for webpage projects?
You can host any kind of code on there
It's good for version control and syncing between your dev machine and your host
Hmm
@toxic turtle Check out the videos from freecodecamp (they are good) https://www.youtube.com/channel/UC8butISFwT-Wl7EV0hUK0BQ
Oh lol, theres a full video guide about everything on there ๐ฎ
Does anyone know how i delete a "repositories" on GitHub if i made a dubblicate by a mistake?
Yeah, go to the repo, click settings -> options and scroll to the bottom and there will be a delete this repository button
Hope that helps
OH, thank you SM!
Long time since I've had a look at anything related to TMP code, including those Gource videos :p
The client and server themselves are mainly C++ and Assembly, most of hte other languages are used for things in the libraries they use
Has anyone noticed sometimes default profile pictures not loading? I've found this to be the same when getting the users profile pic from TMP API?
But it only happens sometimes
it happend to me yesterday on multiple users too
Ye it only does it with the default profile pic as far as I can tell
https://static.truckersmp.com/avatarsN/defaultavatar.png seems to be showing a 502
@tidal zodiac ^ 
Oof xD
just noticed ๐
I assume the 23% would be the default avatars @raw notch xD
Nah, if a user doesn't have an avatar it will just give you the url for the default avatar in the api, instead of an (incorrect) user specific url
Also, @raw notch, which monitoring/metrics system is that? ๐
firebase
Ahh
the firebase console like to app analytics, crashalytics and perf
Ye @north flax it does, however we said above that the default avatar isn't loading sometimes and giving a 502 error
Ye, I missed it since I skipped over it earlier today, before Dowmeister posted the screenshot :p
Oof xD
Anyway, might use the measurement api to throw app metrics into Google Analytis like that. The measurement collection api is simple enough
Or I might just throw it into Postgres, that would also work
Could try the postgres timeseries db extension
@north flax firebase is really easy to implement inside an Android app or a react native app, also on iOS. is a bit challenging in react native because needed modules are a bit demanding as configuration and tweaks in dependencies but it work flawless
Not using react, I was thinking of metrics from requests I send from my serverside app :P
Also, those metrics are sent to Google Analytics, from what I see, so I can implement that manually
ah yes
How do you convert a UTC timestamp to UnixTime (seconds since theepoch)?
How do I put some specific files into the plugins folder inside ETS2 folder when a user decided to install my application.
Use an installer script, like Inno Setup or NSIS.
Could it be done using Visual Studio?
I don't know what MSI installer is capable of.
you can do it with custom actions at least
xD
meh... Idk what's going on with MariaDB local server, but it's awkward...
In order to import to DB,... I need to firstly drop database to which I import xd
@sick anvil registry keys, no need to put in a special directory
or inside the plugins directory in x64/bin of each game
Showing off latest code project, inactivity calendar for my community (staff + VTC Drivers + CC) ๐
Using FullCalendar ๐
Noice. ๐
I'm still learning Laravel, but I'm starting to know more and more with every next lesson of the course.
FullCalendar is really nice imo
We use it for our event game server request system as you might know
https://truckersmp.com/event-request
Just a quick question. Krashnz gave me access to the ets2map API. Are there any other end points other then the one he provided or do I have to figure all that out based on the data provided?
There's 3 endpoints iirc, one for the full map, one for regions, and one for getting a specific player
Ok, does anyone know those endpoints because Krash only gave me the full map one?
You can look at the ets2map source code in browser.
for some reason I thought XP.css was somehow related to ets2map APIs
That's a great idea ๐
Same, but if I would be known in Webdev. then I would do it this way x3 I love Win XP 
How to deal with localization in Laravel?
https://forum.truckersmp.com/index.php?/topic/86522-website-v29-release/&do=findComment&comment=923153
Some changes have been done to our API today 
Is the discord snowflake your discord ID because it's different to my ID?
U wot?
On the API
Your Discord ID is 237968676614045696.
lol
isn't a discord id a long?
That's why we ended up with two Steam ID fields
String and long probably
(correct me, if I am wrong)
Thank you for pointing that out.
I am right - that's so rarely 
Np ๐
@unkempt hamlet Great change thank you ^-^ Could the snowflake id be returned for VTC Members endpoint please? Would make it really easy to match up our list of discord users to VTC Members to make sure everyone on the VTC is in our Discord server
(Happy to write this up as a forum suggestion if you think its a credible suggestion)
You can submit a suggestion on our Forum.
๐ thanks
@quartz moth fixed.
Thanks for the update
That field is string now.
IDs should never be treated as ints 
It depends
^this
I mean - If I am coding my discord bot in JDA -> then it always wants a long or string (I prefer long)
My own ID-System has only 5 digits maximum -> so I can treat it as Integer ๐ (but if we(I) need a longer Number, then it's fast to update it ๐
Is it possible to link up the VTC apply button for external website application?
Nope
But you can just put it in the website section
Aw
is there a way ti make a free web no watermarks
Yes - do it yourself
I mean - if you want to do this over a CMS you have mostly a Watermark in it - if you do it yourself, then only, if you code it in ๐
@shadow marsh can i dm u
You can - but don't expect an answer (I am not the person you are looking for)
For sure there are - use google
but only designing and coding a website is still not enough - you need to host it somewhere and you also need to pay the Webspace then
oh so u cant do it completly free?
Nah
oh
If you don't want to code a website you need a CMS then (or you rent a webdev (if that's possible)) but both can be very expensive, depends on what you want to have
id code it
Have fun then - but still, you need a webspace somewhere to host your homepage then ๐
If you have a second computer at home, you can turn it into a server
nope
It also takes a lot of time to code a website from scratch especially if you're new to it
well i just wanna do it for free
It's in your own hands then.
but were do i host it
I believe you're after setting up a site for your new VTC?
You need to rent a webspace somewhere (and this costs money)
It's not great, but there's a huge amount of smaller companies that will use Weebly, Wix, and other website builders at least temporarily while they're starting up, and then once things have gotten going they'll most likely switch or upgrade or something.
It's not my favourite option, but it does give you a lot of personalisation and it's great for a simple site when you're starting up
A short lesson in web application security:
- never put secrets in the URL
- be mindful of your referer policy
For example: Streamlabs OBS sending valid Streamlabs API auth tokens to my service API. (Don't worry, they fixed it after I contacted them)
IDs should never be treated as ints :rooSip:
@cinder spear Question, why? We store our users Discord IDs as BIGINT but why would you recommend we dont do that?
Hello there,
My VTC's tracker closes by itself. When I run Task Manager it shows suspended. Why is that happening and what could be the possible solution to such an annoying problem? If anyone can help, that'd be great
Well, I store ID's always as String + Bigint (and in the code as long) 
@mossy cloud because IDs should be opaque values. Forcing a type on them you arbitrarily limit the possible values IDs can have and in many cases have to do unnecessary parsing or type conversions.
True, but at least in our case we know Discord IDs always have a certain type, and by limiting it we ensure only correct data can be inserted there.
Obvs I do validation checks as well but thats kinda a last defence on the Database
And we dont have to do type conversions becuase we write the code expecting it to be a (big)integer, because it always will be. If Discord change their snowflake ID system thats the only time we'll need to update our code
@mossy cloud And right there you covered one of the flaws of storing it as a specific type. The big "what if it changes". As your application grows and grows, imagine the work it takes to a single value to a new type? Thats time wasted. You never know what change a 3rd party could do.
As an example: When TMP introduced arcade servers they added an A to the end of your server player id if you are on one. Before that all server player id's were integers. That change was done unannounced and without any info. If one were storing that id as an integer then poof. Instant broken application just like that.
I'll personally never trust external ID's and prefer to have them stored as strings. But its kinda up to whatever you want. Both works.
I personally wouldnt agree it's time wasted, its necessary time spent, although we dont know what changes others may make, if we rely on 3rd parties, we as devs must make sure we're reacting to that and keeping up to it. Just setting everything to string when it doesnt need to be is laziness imo
When TMP introduced arcade servers they added an A to the end of your server player id if you are on one. Before that all server player id's were integers. That change was done unannounced and without any info. If one were storing that id as an integer then poof. Instant broken application just like that.
ID's are still treated as integers. The ID prefix is just displayed, that's all
@opal arch I had always a question on that: why add the prefix?
I mean, it has some functional or programming reason in tmp code?
So we know where the report comes from ๐
If a player gets reported for blocking, and the "A" ID prefix can be seen, we know it is the arcade server for sure and thus, the player should not be punished
But to be honest, I would love to get rid of it. It just feels so bad to have the player ID as a string in certain situations
Is there a reason it taking so long to update for ats and ets for 1.37 support
That's the completely wrong channel
Also I've got a question about Minecraft Java - You all know PermissionEx - I want to avoid PEx and want to code my own Permission system over MySQL (MariaDB) -> Can anyone send me points to figure it out? ๐
Haven't done it myself, but the org.bukkit api does include the basics for a permission system, so I think the main thing you need is to add permissions to user, and update them as needed
You can probably find more information about it by searching a bit
@shadow marsh
Yeh, fine ๐ Thanks HumaneWolf :D
I asked here as maybe anyone may know something about Bukkit + Permission ๐ but thanks ^^
Here's a neat thing if anyone's thinking of making a SaaS product at any point :P
https://www.enterpriseready.io/#
Changing the enterprise software narrative from 'how to SELL to the enterprise' to 'how to BUILD for the enterprise.'
True, but at least in our case we know Discord IDs always have a certain type, and by limiting it we ensure only correct data can be inserted there.
@mossy cloud
Discord's API returns snowflakes as strings so you're already doing some conversion
The RestCord library handles that so although true, not really my concern unless there's no package update ๐
bad library 
Given that all Discord IDs are snowflakes, you should always expect a string.
โDiscord API Reference
RestCord sucks :D
JDA not
I can get IDs as long and Strings 
I am more exited about Windows Package Manager
Hey guys,
I see most of you are talking about web development stuff but I'm gonna still ask this.
Does anybody of you know how to implement Scripting language such as LUA, Python, C# or etc to C++ project. Game Engine for an example.
Lua is almost certainly the easiest of the three
https://www.youtube.com/watch?v=4l5HdmPoynw for example
C++ and Lua work very well together. Using Lua you can create modifiable programs by embedding it into your C++ program. In this video I take an introductory look at enabling data transactions between C++ and Lua.
Source: https://github.com/OneLoneCoder/videos/blob/master/Vid...
and C# requires compilation to bytecode for the .net virtual machine (similar to java)
there's also https://www.compuphase.com/pawn/pawn.htm
Pawn is a simple, typeless, 32-bit extension language with a C-like syntax, suitable for the smallest of embedded systems.
but it can be done: https://docs.microsoft.com/en-us/xamarin/tools/dotnet-embedding/get-started/c
(embedding .NET code in C applications)
I will look onto them, thanks
Lua is a good language for beguinner
maybe stupid question, {{ Form::text('query', null, array("placeholder" => "Search query", "class" => "form-control" )) }} this should reassign the input value with the posted value, right?
@raw notch If I recall correctly you need to move the posted data to session flash data for it to show
@quick glen I thought it is automatic...
Was Form not removed in Laravel 5.0?
^ Pretty sure about that
It's a separate package now
5 years without any update
No, the other one
Laravel Collective
iirc I'm using it from add-on package but it's not what I've asked for :D
Well, it would be hard to give you an answer if you were using something that is almost as old as TMP
and what's the correct way in latest laravel versions to generate forms and manage values in postback?
To generate forms? Write HTML. If you setup templates in your IDE, writing a form is a matter of a minute at max
If the form is sent, you can use old('field') in the view to retrieve its value iirc
Not the most beautiful way, but more flexible
I mean writing HTML gives you much more freedom than relying on a library and hoping it includes all features you need
Especially in something that is that trivial
PhpStorm has a template for input by default. I think that using it saves you more pain than writing echo for a form builder
I disagree. I did several projects in MVC and Razor using similar html helpers and I think it's wonderful for standardize html components, if you haven't a method or a suitable override you can implement it but usually don't need to.
For example i find useful laravel html helpers to print select from an array or a model without doing a loop. or maybe there is another way and I don't know it
and have to print option bla bla bla bla
manage the selected value doing an if... why? it's stupid tasks a dev shouldn't do for each field, helpers are for this
@each('view.name', $jobs, 'job')
Easy.
Selected value can be done with one statement
so you implement a view to replace helpers?
for me it's not the correct way to do it . In Razor you can add extensions to HtmlHelper and virtually extend it infinitely to manage every view component without logic
There is no "correct" way to do that ๐
It's up to standards in your development
for example I had Html.Icon to manage all icons via fontawesome, without writing the i tag every time, a day we decided to implement our icon font and I've changed the icon extensions not a find and replace in the whole code.
exactly, I've added "for me"
Showing off latest code milestone, Dark Theme ๐
Really happy with it tbh โค๏ธ
Ew ๐
Looks slick, ngl

Well I was impressed with how you've done it tbh, so thought I'd make use of it ๐ It's clear for the user that way
format date without seconds :)

๐
Thank youu
Well done, Penguin ๐ Is really nice ๐
Just did a simple AHK script with canned messages for my Steelseries Apex 7 keyboard wheel
I need to move that window to the OLED screen of the keyboard as well

XD
LOL
prints are useful until 1) adding the print somehow fixes the issue or 2) it's in a loop that goes a bazillion times

but proper debuggers are so nice
Well, I do it this way, in every step I do a bukkit.getconsolesender.sendmessage and/or player#sendmessage and so I can see, what it does or what does it not x3
after it works, I delete them afterwards
it's in a loop that goes a bazillion times
I completely agree with this
related https://i.imgur.com/giPffR3.jpg
print in loops? 
My debugging tool:
dd("nootnoot") ๐
Exactly me
Afaik no - just buy one.. it's really not expensive unless you want one like .io or .game or whatever
There are free ones like .ml, .cf and .tk (and a couple of others) I believe, but they're not great ๐
There's a ton of different paid ones you can get on the cheap though, so I'd definitely recommend looking around for your favourite
Most of the free domains are blacklisted by browsers and antiviruses
Maybe a stuppidy question, but how you test Laravel projects? ๐
Any of you using Prism Telemetry SDK? I can't find the info if blinkers state are available via telemetry?
I want to port keyboard lighting features to Steelseries
Nevermind ๐
Found it?
Well crap...
After moving my project etc, I hit the ground with error Declaration of Carbon\Translator::setLocale($locale) must be compatible with Symfony\Contracts\Translation\LocaleAwareInterface::setLocale(string $locale)
Nvm - sorted out.
I'll link to my first project so you can take a look.
https://pkm.arkadiusz-fatyga.eu
It's not so big (and still some things has failed at beginning and some work needs to be done), but it works. ๐
Might want to check your responsiveness :)
For sure - I saw that. ๐
Great job though 
Thanks ๐
Steelseries Apex 7
Okay 
Looking nice, would be nice if I had that ๐
It's so dumb right now, basically I am grabbing API data from funbit telemetry app, then shoving it to steelseries rest api.
But still.. a great idea 
You could implement this in TMP for those, who have this keyboard 
Nah
Great job CJ, looks awesome ๐
When you have the hazards on maybe have the [ ] flash green as well? ๐
They do
It sucks that the keyboard doesn't have a neutral light state. Either a pushed state or black. Bummer.
Very nice that you did a direct implementation of it. I've used software like Aurora and Artemis in the past to achieve something similar with my Corsair one
http://www.project-aurora.com/
Wow
Does it catch Razer Chroma data from the game?
If so, then I have wasted a full day on that for nothing.
I can't say I know if it works for Razer as I don't have any RGB Razer devices
And it's not wasted if you learnt something new :)
And it doesn't work

https://github.com/antonpup/Aurora You might be able to fix it with what you worked on today 
The dev branch seems to get updates
It's working
That's why restcord sucks
alternatives?
Nope
Aurora pushes bitmaps instead on events, how clever.
oh worked... is not restcord.. is composer ๐
Well, Aurora is cool, but janky as hell.
damn that keyboard is cool
Yes is so cool
Should I let it being normal or this? https://prnt.sc/snin5h
What's this?
that's for the console... I thought I can decorate it a bit... otherwise I just see something from SLF4J and JDA...
Your project - your rules 

also true
wanted just your opinions - I prefer it non-cursive ๐
This cursive text makes for me flashbacks when the trojans were written in 80s/90s...
(maybe I'm too old for my age...
)
lul
cursive is for lazy people like me who want to write faster lol
I have my own company on Ats,let me get to the point how do you make truck delivery show up in the discord server when you are done delivering the load.
I need help.
It's a third-party software, you can search for them in Google.
What is some third party software.
I wanted to ask. Is there a discord bot able to send private message for a specific role from the members on the server?
You can use Dyno, but you need to create a custom command afair.
Now to my topic (with which I came here) - I've updated my website.
Made some tweaks to layout of some things, check it out right now. ๐
https://pkm.arkadiusz-fatyga.eu/
anyone has experience in securing api in Laravel without using the UserModel but something else like an ApiClient model? i'm trying to use https://github.com/tymondesigns/jwt-auth but it's not really clear how to use it with another Auth Guard.
auth.php -> guards
'jwt' => [
'driver' => 'jwt',
'provider' => 'apiclient'
]
auth.php -> providers
'apiclient' => [
'driver' => 'eloquent',
'model' => App\Models\API\ApiClient::class
]
and then using the middleware auth:jwt
$token = auth('apiclient')->attempt($credentials);?
@unkempt hamlet actually if i call the route with middleware auth:jwt it redirects to the homepage
What version?
I mean jwt-auth
ah latest from composer
yes using middleware auth:jwt
and that route redirects to homepage
otherwise there is a good jwt composer package to use to implement a custom middleware?
Just a thought (I could well be wrong here, take this with a pinch of salt) if Laravel is 5.8, wont it need to be registered in your AppServiceProvider so that the facade can be used?
5.8 should have autodiscovery. but I've registered the provider too
How to install TruckersMP on Linux
Open a terminal.
And do
sudo rm -f /*
I hope you've liked my tutorial
finally, I've solved the jwt thing implementing my own middleware
Hmm. Thought of a method that would make it possible to implement synchronized jobs and a server economy by seriously abusing save game loads :p
to be slightly more specific, a method that doesn't require reverse engineering the game itself to work. You could still improve it with reverse engineering though, making a way for you to trigger save loading externally so that the user doesn't need to do it
You can ask questions here. It's been written on by a bunch of people throughout the years of her existence
In that case, I think @opal arch might be the person to message
Dunno if he owns the bot "account", but iirc he has at least written a bit on it after I left the dev team
Yes, we own the bot as a team, though
@ember canyon can you send a message to @opaque oriole, please?
If there is a vulnerability allowing someone to get part of the config, I'd like to hear the details after it's been fixed
Same, to be honest ๐
I am not aware of reading the config anywhere where it would allow to do such a thing
Except for eval which is available for owners only, of course
Neither am I, based on what I remember from when I last worked on it
Ah, nice. I started a TypeScript rewrite ages ago, but never finished it
I can say that I have ModMailed it
Are you sure?
@hazy night is rewritten to TypeScript thanks to @cinder spear. I am now finishing the v2 of it
@meager spoke he has, I moved the ticket
No worries, I was quick 
Shawny is fast ๐
@opal arch I hope that you did not stress a lot when I sent it.
Nah, the bot just manages a guild with 102k members, I have not really stressed 
Even though I have not been aware of any issue
Long time since I looked at a bot token, but guessing the start is the bot id or something, not the secret
@north flax I will send you a message
My bot runs on node.js
even lethal is better then me
Only thing I've used nodejs for in the last year is compiling a vue and an angular app
I think
๐ Chris

I'm using Node.js for my bot too
But I lost the main file
๐คฃ
I had to use the dev version
should use git
How to install TruckersMP on Linux
Open a terminal.
@ember canyon well its possible to play on linux u know right
what's wrong with bots in nodejs or node in general?
Nothing, really. The lack of type safety can cause issues, it can enable front end devs to write insecure back end code, etc, but node in itself is fine
It's good at some things, not at others, like most other languages and runtimes
I'd argue nodejs can be good for a bot, because it's easy to write quick async code to handle events in real time
If you want to do heavier or time consuming calculations, however, you might want to use something else if you want it to be optimal, since heavy calculations are not a perfect fit for it's event loop. That something else can be in addition to nodejs though, doesn't have to replace it.
ah
@north flax yes, it depends, as always
and btw, for type checking, there is TypeScript
Ye, you can use Typescript. I prefer TS over JS myself
You can also write Kotlin/JS for node
Haven't tried that myself though, but can be good if you want to use the node runtime in a kotlin environment
personally i love node but only for some uses
you can also use wasm in node but at that point why not just write directly in the language you're using
Main reason I can think of would be to run it on the node runtime and use the event loop
async is quite good as you know how to use it without impact performances, actually the event loop is really hidden, just take care of way you use async and in some scenarios, be aware of the single thread
Trucky use widely async on app and on API, mostly with await but there are many cases when await is used inside foreach or big loops, implement custom promises or use cascading .then() is better than many await
Can anyone recommend a good rich text editor. I saw https://quilljs.com/ but was wondering what everyone else used?
Thanks CJ, summernote seems good so Im gonna try that ๐
Oh my
Someone have a problem for reduce gif weight
Hi, is there still a lot of bug for the update ?
This is not a place to ask questions about TMP updates.
sorry ! i didn't read the descripiton of this channel sorry
Can anyone recommend a good rich text editor. I saw https://quilljs.com/ but was wondering what everyone else used?
@quartz moth We also now use Summernote ๐
Tbh, I personally like VSC for what I do & works very well.
What are you talking about?
He talks about Visual Studio Code lol
I know, but there was no conversation prior to it 
stupid question: how to upgrade from laravel 5.8 to ^6.0? i've updated composer.json and then composer install, nothing changes, tried to launch composer require laravel/framework:^6.0 but php artisan --version still returns 5.8.
If you change it in composer.json to ^6.0, you need to run composer install
If that does not work, you might be using dependencies that do not support the newest version, and therefore, the installation is not successful
Check the log for more information
and i did it, actually i managed with composer update laravel/framework after changed the composer.json
but the problem is now dependencies
That they do not support Laravel 6.x? 
@opal arch yes I think they do, but I have to update them one per one verifying which version is good
You can just check them on Packagist
but always one per one
But you can quickly open the page and go through versions
Jesus... I wanted to attach this module, but I still have an issue with jQuery. 
~~https://github.com/terrymun/Fluidbox~~
As I check it thinks that $(...).fluidbox is not a function
Runs away 
I've switched to another version, which actually utilises npm. 
Updated website - you can check it here -> https://pkm.arkadiusz-fatyga.eu/
Hello creators of TrucksMP, do you have any chance of placing this vehicle? Just for curiosity
more trolling?
@glass parcel When the world is perfect, you and I will probably not be here to see where cars and trucks go smoothly, without accidents
Sorry : (
i dont see any reason for putting this in a TRUCK simulator
skoda drivers are just trolling around
i dont see any reason for putting this in a TRUCK simulator
This is not a place to suggest something for TruckersMP.
where i can report a "bug" in the TMP PHP API client documentation on github? i'm not sure it's a bug or simply a different way to do the same thing. here or in the forum?
Make a github issue 
oooook
Added
groupColorto the/v2/playerplayer API endpoint
Just a little update to the API
Oo thanks for the update Shawn
GIMP?
ETS2 k
laravel is creating session cookies on domain with leading dot so they will be valid on all subdomains but i dont want to. SESSION_DOMAIN env is without leading dot and session.php under config doesnt change this value. Any ideas why? it's by design?
Huh, I don't see that happening on our website. Looks like it's the feature of latest versions.
it's 5.8
@unkempt hamlet have you SESSION_DOMAIN env explicitly configured or is null/empty/missing?
must be that one... if defined, laravel add a . .... it's strange and dangerous
Just when you thought this year couldn't get any worse: https://github.com/git-for-windows/git/issues/2674
Git are trying to drop the term 'master' which is going to break a metric ton of stuff
if people want to take the time to use more inclusive naming and make it easy, I don't see a problem
It doesn't make any sense

Did you change it? Or is it default now?
also, SCS uses naming "slave trailer" for the second trailer... is it also non-inclusive?
I just changed it
I don't see any problem with the word master in the way its used in GIT
It all depends on the context it's used in. Any word can have bad connotations if it's used in a certain context
ยฏ_(ใ)_/ยฏ
git itself can be used wrong in a certain context xD
at work se use Dev - main - release but not master (and not on git, on tfs)
ESX Framework (FiveM)
Use Legacy - master - dev - antishit - jobs
Oh my
neat
Why "oh my" what do I not see 










