[QUOTE=awcmon;48303910]Is Visual Studio 2015 worth it or should I stick to 2013 for now? I've been a bit out of the loop.[/QUOTE]
If you're a C# dev, absolutely. It's the only way to compile C# 6, which many [open source] projects are already upgrading to. It doesn't bring any major features, but it adds quite a lot of useful syntactic sugar.
[QUOTE=awcmon;48304065]OH SHIT IT COMES WITH IMPROVED C++ SUPPORT?
FUCK YEAH
and yeah i use it for C++, but might give C# a spin because it looks like what all the cool kids are doing these days[/QUOTE]
It doesn't significantly improve the C++ support, but ReSharper C++ does. If you're a student, you can get a free license.
Today I implemented standard library functions because my university wants us to compile using MinGW 4.7.1 and it's so old.
[QUOTE=awcmon;48303910]Is Visual Studio 2015 worth it or should I stick to 2013 for now? I've been a bit out of the loop.[/QUOTE]
Certainly nothing worse with it. .NET 4.6 support, better C++11/14 support, ASP.NET 5 beta and I think by extension .NET Core support. Much better C# refactoring, the ability to use Roslyn analyzers for additional functionality there. New GitHub plugin if you use GitHub.
[QUOTE=awcmon;48304065]OH SHIT IT COMES WITH IMPROVED C++ SUPPORT?
FUCK YEAH
and yeah i use it for C++, but might give C# a spin because it looks like what all the cool kids are doing these days[/QUOTE]
It's still MSVC, so improved doesn't really mean a lot.
[vid]http://files.1337upload.net/Desktop_07.27.2015_-_16.11.26.03.webmhd-45cdda.webm[/vid]
camera flashes
if its too dark it will automatically use a flash
it also has some cool debug visualizations
[QUOTE=DarKSunrise;48303941]what are you using it for? c#? c++? support for modern c++ is a bit better but it's still lagging behind other compilers[/QUOTE]
I like Visual Studio for C++ since the VC++ debugger is more intuitive IMO than GDB. Of course it totally owns for C#, and take my word for it, my job is C#.
[QUOTE=DarKSunrise;48305029][vid]http://files.1337upload.net/Desktop_07.27.2015_-_16.11.26.03.webmhd-45cdda.webm[/vid]
camera flashes
if its too dark it will automatically use a flash
it also has some cool debug visualizations[/QUOTE]
Holy shit. TECHNOLOGY. I love stuff like this.
[QUOTE=Protocol7;48305113]I like Visual Studio for C++ since the VC++ debugger is more intuitive IMO than GDB. Of course it totally owns for C#, and take my word for it, my job is C#.[/QUOTE]
[url]https://github.com/Microsoft/MIEngine[/url] might interest you if you want to use GDB.
EWMH support \o/
[img_thumb]https://hostr.co/file/g8BoCmIrB3TS/Screenshotfrom2015-07-2718-00-08.png[/img_thumb]
lxpanel correctly allocates screen space and shows the workspace name, and wmctrl sees all the stuff
So I'm trying to make a tool for my game that calculates orbital period but it keeps spitting out NaN. So I print what my different values are for my orbital period calculation:
[code]float period = 2 * pi * Mathf.Sqrt( ( a * a * a ) / mu );[/code]
and for some reason my mu value, which is [I]mass x Gravitational Constant[/I], is negative so it's square-rooting a negative. :s:
Turns out that for the past 2.5 years of working on my game, my [URL="https://en.wikipedia.org/wiki/Gravitational_constant"]gravitational constant[/URL] has been negative when it should be positive.
Everything works the way I want it to right now so I think I'll leave it negative and just use the absolute value of mu. Making it positive will probably break how my negative mass objects behave and who knows what else.
[editline]|[/editline]
I wonder what kind of sorcery I've conjured up over the years to accommodate for that sign change :v:
[QUOTE=Pelf;48305801]So I'm trying to make a tool for my game that calculates orbital period but it keeps spitting out NaN. So I print what my different values are for my orbital period calculation:
[code]float period = 2 * pi * Mathf.Sqrt( ( a * a * a ) / mu );[/code]
and for some reason my mu value, which is [I]mass x Gravitational Constant[/I], is negative so it's square-rooting a negative. :s:
Turns out that for the past 2.5 years of working on my game, my [URL="https://en.wikipedia.org/wiki/Gravitational_constant"]gravitational constant[/URL] has been negative when it should be positive.
Everything works the way I want it to right now so I think I'll leave it negative and just use the absolute value of mu. Making it positive will probably break how my negative mass objects behave and who knows what else.
[editline]|[/editline]
I wonder what kind of sorcery I've conjured up over the years to accommodate for that sign change :v:[/QUOTE]
Is your gravitational constant negative ? If so try using the absolute value of it (so -9.8 becomes 9.8)
Edit :
Oh wow I totaly looked of that on my phone and only read the top part, too bad we don't have the bad reading rating anymore or I would have rated myself ...
So I was making random loot for my game and realised I needed a function that would [b]accept variables (left, right, coolity) and return a random float between left and right, with probability to return a value close to right increasing with higher coolity[/b].
The use case: the player is fighting an enemy that should drop good loot. I have to make it so the loot is random and there is a chance to get the absolute worst possible item, but the chance to get a better one is significantly better.
Here it is!
[code]
def clamp(value, range_min, range_max):
return max(range_min, min(value, range_max))
def random_in_range_for_coolity(left, right, coolity, mode_divider=3, coolity_multiplier = 2):
coolity_effect = random.uniform(0, coolity) * coolity_multiplier * 2
mode_divider = clamp( mode_divider - coolity_effect, 1, 999)
mode = clamp( int( (right) / mode_divider), left, right )
return random.triangular( left, right, mode )
[/code]
left, right are self explanatory.
coolity can be between 0 and 1(Actually can be anything, but results are stupid with differing values).
mode_divier means where in the range is the expected value. 3 means on average you are most likely to get a number at 1/3 of the range. For example if you had numbers [1, 2, 3, 4, 5, 6], with mode_divier = 3 you are on average most likely to get 2. Higher mode_divider means less chance to get top values, lower means more chance to get top values.
coolity_multiplier is just a number for tweaking how much coolity shifts the chances.
Now let's see it work.
[b]Getting numbers between 1, 100 with various coolity.[/b]
Coolity = 0
[code]
left = 1
right = 100
coolity = 1
randoms = []
for x in range(10000):
randoms.append(random_in_range_for_coolity(left, right, coolity))
top = list(filter(lambda x: x > 0.8*right, randoms))
bottom = list(filter(lambda x: x < 0.2*right, randoms))
[/code]
Produces:
[quote]
Avg rangom 61.957698
2809 top value occurencies
505 bottom value occurencies
6686 middle value occurencies
[/quote]
Almost 30% chance to get a top value. Means players have a 30% to get a top item (or item property).
Same thing for coolity = 0
[quote]
Avg rangom 44.646323
596 top value occurencies
1136 bottom value occurencies
8268 middle value occurencies
[/quote]
You get mediocore and bad items mostly, around 5% chance to get a top value.
I use it to generate damage and accuracy for weapons. Which are represented as dice rolls ("1d6" stuff).
Getting 10 random dice between "1d1" and "6d6"
Coolity = 1:
[quote]
6d4, 3d6, 5d4, 5d3, 5d2, 4d6, 6d5, 4d6, 6d6, 6d5
[/quote]
Mostly around the right boundary, top values. Even got the absolute highest.
Coolity = 0:
[quote]
3d3, 2d6, 3d4, 2d2, 3d4, 2d6, 3d3, 4d6, 4d2, 2d2
[/quote]
Some mediocore stuff, some bad stuff, a bit of good stuff.
Yeah it's basically a wrapper around triangular distribution.
[QUOTE=Winner;48306388]that was like the entire point of the post what the heck[/QUOTE]
Yeah I just edited my own post, I completely misread that whole part post on my phone and only saw the top sentence and the code :suicide:
Even if you're creating an obscure embedded system in the 1980s for a single family of machines you should still try to at least make your code consistent in naming or number conventions or literally anything. Don't make getting/setting everything it's own special case with it's own naming convention and format. ESPECIALLY when it requires serial communication that works at worse than 1 character/millisecond, including an echo of the entire command before the result.
Someone WILL have to deal with your shit code 20-30 years down the line for whatever reason and they will hate you for it
At least I'm nearly finished with this unholy mess of a project. I don't know how I've kept my sanity
So recently I made a thing for Mcdonalds, I work there, (I'm only 16), and they have online quizzes that you pass to get stars and crap, just dumb stuff. Well, they are dumb and you can just post request a stupid answer, as long as you send out the quizid, question id and your session code, you can get any answer without submitting anything, so for each question my code sends a fake post to the server pretending im choosing option A, server replies with correct answers, my code chooses the correct answers and continues.
Is it worth creating a quick better system, and writing up a document on word about this and sending it to the it department at maccas, will they just not care? Or will I maybe get a response and get to talk to someone from there. For me, I feel like it could be good, it can't really go wrong, I doubt they would be angry.
[QUOTE=PigeonPatrol;48308502]So recently I made a thing for Mcdonalds, I work there, (I'm only 16), and they have online quizzes that you pass to get stars and crap, just dumb stuff. Well, they are dumb and you can just post request a stupid answer, as long as you send out the quizid, question id and your session code, you can get any answer without submitting anything, so for each question my code sends a fake post to the server pretending im choosing option A, server replies with correct answers, my code chooses the correct answers and continues.
Is it worth creating a quick better system, and writing up a document on word about this and sending it to the it department at maccas, will they just not care? Or will I maybe get a response and get to talk to someone from there. For me, I feel like it could be good, it can't really go wrong, I doubt they would be angry.[/QUOTE]
It might get you a job as a programmer rather than cashier :v:
[QUOTE=Winner;48308869]even if it's a shitty mcdonald's quiz site any company will be appreciative of being told about vulnerabilities[/QUOTE]
I can also access any quiz, even ones I don't have access to and answer them.
[QUOTE=PigeonPatrol;48308502]So recently I made a thing for Mcdonalds, I work there, (I'm only 16), and they have online quizzes that you pass to get stars and crap, just dumb stuff. Well, they are dumb and you can just post request a stupid answer, as long as you send out the quizid, question id and your session code, you can get any answer without submitting anything, so for each question my code sends a fake post to the server pretending im choosing option A, server replies with correct answers, my code chooses the correct answers and continues.
Is it worth creating a quick better system, and writing up a document on word about this and sending it to the it department at maccas, will they just not care? Or will I maybe get a response and get to talk to someone from there. For me, I feel like it could be good, it can't really go wrong, I doubt they would be angry.[/QUOTE]
it'll be like that scene in idiocracy where he solves some menial bullshit and become president of the united states
[QUOTE=PigeonPatrol;48308502]So recently I made a thing for Mcdonalds, I work there, (I'm only 16), and they have online quizzes that you pass to get stars and crap, just dumb stuff. Well, they are dumb and you can just post request a stupid answer, as long as you send out the quizid, question id and your session code, you can get any answer without submitting anything, so for each question my code sends a fake post to the server pretending im choosing option A, server replies with correct answers, my code chooses the correct answers and continues.
Is it worth creating a quick better system, and writing up a document on word about this and sending it to the it department at maccas, will they just not care? Or will I maybe get a response and get to talk to someone from there. For me, I feel like it could be good, it can't really go wrong, I doubt they would be angry.[/QUOTE]
You sure it's not recording the wrong answers based on your session ID? From the back-end, they might be seeing a constant influx of wrong answers immediately followed by the right answers.
[QUOTE=icantread49;48309135]You sure it's not recording the wrong answers based on your session ID? From the back-end, they might be seeing a constant influx of wrong answers immediately followed by the right answers.[/QUOTE]
No because I've gotten badges at work by doing this :v:
It also shows the history of your attempts and mine are all 100%. Also, I can get the answer of a random quiz and a random question, the session ID is generated when you start the quiz too, and I've seen no link to the session ID and your account, as I can generate a session ID without being logged in.
If my judgements are correct, and judging by the source I've read. It keeps track serverside and the values can be overwritten.
Theoretically, I could do the test in any order and as much as I want as long as I don't submit the last question, then when I submit the last question, it'll just recognise all the latest updated answers.
I can tell the server keeps track of my answers because the client never sends the answers as one big table at the end, so the server obviously just creates a table of answers using the session ID and has no checks serverside to see if an answer has already been put in the array or whatever.
I imagine there function is like
[code]
function inputAnswer( sess, id, ans) {
// validation to check if ans is a number maybe?
// check if sess and Id are valid.
// no validation to see if question already answered
quizAnswers[sess][id] = ans
}
[/code]
Obviously simplified version
They need to fix some stuff, I can get a session Id without being logged in, and their prevention of bots is dumb, their solution is to generate a token when you load the login page in a hidden element, which becomes valid for a few minutes, so I can just post request the loading page, scrape the page for a token and I got one to use to login.
Ha. Nice research you got there. Yeah, sounds like they're doing some pretty dumb stuff.
It's not really surprising to me that their employee center is not too secure. They don't really expect anyone to be messing around with it. I think it would be fine if you send them some genuine concerns, but be careful - they don't need you, so if they feel threatened in any way (keep in mind your message might land in the hands of some dumb manager that can't tell the difference between a monitor and a computer), they might cause problems with your job.
I got idea for game:
Idea: Don't touch the AD with the ball rolling on the ground
And there would be enemies : ADs.
Those ads would be 3D signs showing ads (loaded from AdMob) that flow down the screen. Your ball progress toward the goal, and when you touch ad cube with ball, it would load advertising to the user.
Sounds good or bad?
It's really scummy I think, should rethink my goals. Thanks for clarification.
You're not allowed to do anything which could potentially make the user mis-click on an ad.
If the stats show your users immediately closing links most of the time, they'll catch on pretty quick.
[QUOTE=Fourier;48309627]It's really scummy I think, should rethink my goals. Thanks for clarification.[/QUOTE]
You could still check if there's some shady ad network that allows it.
[img]http://i.imgur.com/XNSSEEr.gif[/img]
got a few things done since last time: subweapons can be retrieved out of chests containing them, did some stuff with how the level draws itself, which then led to me implementing simple 3-frame animated tiles
[QUOTE=No_0ne;48310415][img]http://i.imgur.com/XNSSEEr.gif[/img]
got a few things done since last time: subweapons can be retrieved out of chests containing them, did some stuff with how the level draws itself, which then led to me implementing simple 3-frame animated tiles[/QUOTE]
I like how you can turn into a chest! :downs:
I just discovered that using prototypical inheritance, I get flyweights for free!
[url=https://bitbucket.org/Nabile/hitbox-for-vlc][img]https://bitbucket.org/Nabile/hitbox-for-vlc/avatar/128/?ts=1438071126[/img][/url] [url=https://bitbucket.org/Nabile/hitbox-for-vlc]Hitbox for VLC.[/url]
It was significantly simpler to retrieve media URLs with Hitbox. Unlike Twitch, there's no JSON involved, you just input the streamer's username or the video's ID into a specific URL and voilà.
Mirror sprites yo
[img]https://dl-web.dropbox.com/get/MuhSprite.gif?_subject_uid=15470356&w=AABdp50FbqqRfMA9jX5KGOHgVp89jeYVo2vAzagRf9onWA&size=1280x960&size_mode=2[/img]
Sorry, you need to Log In to post a reply to this thread.