I noticed that the MEE6 bot has these cool custom pictures (well, not really pictures, graphics, maybe, but whatever). If you don't know what I'm talking about, take a look.
Notice here that the text and icons are different for each user. More importantly, they implemented this into an "image". How would I do this (if it's possible)?
I would want to use this in discord.js, as a command. Don't worry about the command handler, I have it ready. Please present your ideas in module.exports = {} form. Thank you!
EDIT: Oh yeah, I know there's such thing as embeds. However, you can't implement a user's icon in embeds, nor do they have different fonts (I think?). Do I have to import any packages for this? Thanks!
The package canvacord makes making a rank-card really easy. It's even built into canvacord! (See here)
If you want more control over how it looks, you're able to make it yourself wit for example canvas
(Little note for Phúc Lộc Nguyễn, that doesn't look like javascript at all, more like python, so I don't know what your intention was..)
Related
First of all, I'm an absolute noob and have only just started learning code - this is my first proper project and I think I'm at the final hurdle.
I'm currently trying to create a bot (with Katalon Studio, which is similar to Selenium) but are having a problem with the reCAPTCHA element. Yes, I understand the premise of reCAPTCHA and it's designed for this exact reason but it's becoming a pain in the ass when trying to test and build out the bot whenever I have to log in and complete the reCAPTURE exercise every single time. It's also an essential part of moving from page-to-page.
I have discovered a Chrome Extension which essentially transcribes the audio capture into text and solves it. However, I'm having actually having trouble locating and identifying the reCAPTCHA object element within the WebUI - I think it's due to being contained within an iframe and it's done like this on purpose.
There appear to be solutions using Selenium as I've found the following two links which suggest it is possible:
How to click on the reCAPTCHA using Selenium and Java
https://www.browserstack.com/guide/how-to-handle-captcha-in-selenium
I'm wondering if anyone has experience around this or any suggestions / advice / better ways of approaching this? I'm open to try anything as this is the last hurdle in getting the bot fully up and running - I don't really want to give up as it's my first project and will majorly help out a friend.
Speaking to the domain owner isn't an option and allowing them to disable reCAPTCHA is not an option. Are there workarounds / other Chrome extensions that I should look into?
Well reCaptcha is made to protect websites from bots, you shouldn't even try to break it in the first place, maybe try using the API, if it exists, instead.
If the API don't exists maybe use OAuth2/ask the user to complete it, don't try to break it with a bot, it is very hard, and most of all shouldn't be done.
I want to create a notification icon with Dojo, but I'm not sure where to start.
The icon has to be similar to those found on Facebook and Whatsapp, showing how many new messages/notifications you have.
I've been looking in the Dojo reference, but couldn't find a good widget to use. Maybe I'm missing something obvious, but I might as well ask it here.
Googling hasn't been of much use unfortunately.
As far as I know there's no widget that automatically does the stuff for you. This problem is far too specific to provide a general widget for it. You also have to think about several things before you can start.
Do you want to use WebSockets? The web is generally made for pulling content, if you want to push your notifications from your server to your client, then you will need to look at WebSockets. A good tutorial to use them can be found on Sitepen.
If you don't want to use websockets (you're not able to create a websocket server or you have some other reasons) then you will probably have to use a simple "REST service" and obtain the amount of notifications from it. This means you're script won't be "live", so you will need to pull the content from the webservice every X seconds/minutes. This means you need a normal AJAX request which can be done with the dojo/request/script module.
If you need to time this AJAX request, you can use the dojox/timing module.
This is only the "logic" part, the user interface (icon + # notifications) can be made by yourself with plain HTML and CSS.
What about dojox/mobile/Badge:
http://livedocs.dojotoolkit.org/dojox/mobile/Badge
?
From comment:
"Maybe you can find something in the DojoX library" -
off course you will find much.
I would recommend
dojox/socket
see http://dojotoolkit.org/features/1.6/dojo-websocket
I would like to generate state diagram, for example as shown in the picture below.
I want to make this user friendly. If any user wants such diagram then he can just drag/drop the circles/arrows and connect them and put description (1,2,3..... a,b,c....) etc. It should be web-based.
I am not sure if there is opensource/free library to do this.
How to generate such diagram interactively ?
Any idea/suggestions are most welcome.
Thank you.
I was looking for something along the same lines and found: JointJS. It looks like very promising for your purposes. The examples should help get you started.
As far as I'm aware there is indeed no opensource/free library that does this.
Some online tools exist, but they mostly use a text-to-image convertion similar to what yUML and Websequencediagrams do.
You'd have to write the whole thing yourself, although something like RaphealJS or jQuery SVG could do some of the heavy lifting for you in regards to rendering the graphs.
You might want to take a look at Canviz and wwwsqldesigner for inspiration.
Finite State Machine Designer can be used to generate diagrams like that in the question with clicking/dragging/dropping.
It's also open source, should you need to extend it.
Have look at my web based State Machine Diagram Editor. A more convenient desktop version also exists.
I'm working on a browser game for facebook/orkut. The graphics and the JSON data have been given to me. My work is to organize the information received in the JSON on the screen. To do this I use css+jquery+javascript (most of the time jquery). I'm not as productive as I'd like to be. My development enviroment is:
eclipse
firefox
firebug with cssUpdater and other firebug plugins
I still have to make every little thing by hand (barebone) programming. For example, to make a screen, I have to make the divs, work the css, and then put it to jquery. This process takes one day to make just one screen workable. I want to know if there is some way to be more productive, such as with a tool to help with the css positioning and updates. Or something to help with the debug process more than firebug does. I tried coffescript, but I don't have the time to learn it right now, and my enviroment is Windows. I see that coffescript works better in linux, but my real problem is css positioning/debugging.
tnx for help.
gameQuery is a jQuery plug-in to help make javascript game development easier by adding some simple game-related classes. [this is your best bet]
Also have a look at these plugins that show you some cool ways to make games in jquery
Also some really good tips here
Here is another experimental library for 3d stuff
Send us link when you are done so we can kill some time on your games ;)
Which is a better approach for this?
ActionScript3 or JavaScript+PHP?
And if anyone came across an open source tool with either I'd really appreciate it.. after a long search, the only good example i found was this http://www.ajax-image-editor.com but I'd rather have a flash alternative.. Also I don't need all the extra functions such as filters.
Thanks.
Flash and Actionscript would certainly have their advantages, but I know no Open Source solution in that field. In Javascript, there is the Prototype based Cropper. There is at least one more good open product out there, but I forgot the name.
This is more of a front-end technology choice. Neither Flash nor JS can store an image on the client side on their own. Both will behave like RPC clients, sending requests to the server to execute.
Whether you choose Flash or JS depends upon your needs (Flash would allow more manipulations than JS) and skills.