Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Uriah

Pages: [1] 2 3 ... 18
1
Web Oriented Coding / Re: Learning web oriented programming
« on: August 25, 2014, 06:43:19 am »
He ment is is not a programming language, but a mark-up language.
Yeah that's what I meant. I should have been more specific though, as not to confuse people who are learning.

2
Web Oriented Coding / Re: Learning web oriented programming
« on: August 21, 2014, 01:12:41 pm »
Schalla: HTML/CSS aren't languages so I didn't specify them in that way. Of course, if learning web development in general you should learn those two first, but since I dont know what he knows and he just asked for a language I gave JS and merely suggested the rest of the tech stack.

So far much as php vs JS goes it really depends on whether you're looking for server side or front end development. I recommended learning JS either way eventually because it's big on the web and will help you understand the other developers you may find yourself working with.

Geoff: I agree with your statement on PHP, but unless server side dev. is what he was looking for he has no choice but JS. I guess our answers our different because we interpreted the question differently. When I see web oriented I think JS because it's the largest player as far as the web is concerned.

OP: Basically: if you're going for client side development: Learn HTML/CSS, and then javascript. If you want to develop on the server side with a language that will help you learn other languages and grow off of, learn PHP. But as Geoff said a rudimentary understanding of the former technologies is important as well, since you might find yourself involved with them a bit every now and then.

3
Web Oriented Coding / Re: Learning web oriented programming
« on: August 21, 2014, 09:02:49 am »
Learn javascript. It's the language of the web. It might also be helpful to learn HTML and CSS at the same time, although those are not programming languages. They are also very simple and easy to learn. If you want to do server side programming primarily then perhaps PHP but afterwards you should still learn javascript IMO.

Also, there's a few things that you can do concerning "web oriented" programming so if you get a little more specific maybe we can help you more in that niche area.

Good luck!


4
Hacking and Security / Re: Why I don't hate the NSA
« on: June 07, 2014, 06:44:13 am »
Also keep in mind that some of the NSA's tactics actually make us less secure. Planting backdoors and secret exploits into extremely important code is more stupid than i ever would have thought possible.

Also, the NSA is a United States organization, meaning that it should abide by the United States constitution. But much of what it was doing was extremely questionable, unconstitutional, and unnecessarily hidden from public knowledge. Even if you agree with the spying, perhaps we should have at least known about it or had the decision? And other countries have sovereign rights as well. Why should the US force it's skewed philosophy on privacy on the rest of the world?

5
Found it on the Webs / Re: Untrusted, awesome open source JS game
« on: April 23, 2014, 07:20:20 am »
On level 21 right now, last one :D Dont have time today to finish though so I'll see tomorrow. Very cool game...

Glad you like it :)

6
Operating System / Re: (Link) A Guide to Writing Your Own Complete OS
« on: April 23, 2014, 07:18:56 am »
Amazing find, +1. Might have to find time to do this just to learn someday.

7
Found it on the Webs / Untrusted, awesome open source JS game
« on: April 23, 2014, 03:28:38 am »
This game is pretty cool! I love things like this, where you actually modify the code in the browser to outsmart the game. Plus, it's open source. :D

Github: https://github.com/AlexNisnevich/untrusted
Game: https://alexnisnevich.github.io/untrusted/

8
Web Oriented Coding / Re: Graph.js
« on: April 18, 2014, 03:55:47 am »
Some things were added since I last posted here if you guys want to see the new animations and such. I know some people here are minimalists so ofc you can turn off the eye candy.

I also thought I should leave this:
http://canvaskite.com/marketplace/webpro/dark-theme/index.html
and this: https://evilzone.org/found-it-on-the-webs/stumbling-across-something-you-made/
here. It uses this library!

9
Found it on the Webs / Stumbling across something you made
« on: April 18, 2014, 03:52:39 am »
It's so awesome to visit a website randomly and then realize it uses your open source code! I was looking at this template for some design ideas: http://canvaskite.com/marketplace/webpro/dark-theme/index.html
when I saw the big graph (last graph on the page). I thought to myself: Oh that looks pretty cool! But I thought there were no SVG graph libraries around that work like that, which is why I made my own. So I was really angry for a second, thinking I wasted my time when there was already a library out there that worked apparently much better than mine. But then I clicked the button to view another type of graph, and saw the animations run. I got a WHOA feeling, looked at the source code, and sure enough, it uses the library I made for graphs.

It feels amazing to know that you've contributed to the web and made something other random people actually use and like. Especially when it works nicely. :D Also, I'm a horrible designer so this looks much better than my examples on the github page, which is what caught me off guard.

My Code: https://github.com/uriahsanders/Graph.js

10
Hopefully by this Sunday. But at this point things are getting a little closer to my idea of beta than i thought. You guys might see a fairly complete site.

11
Web Oriented Coding / Re: Pong in JS [Tutorial, sort of]
« on: April 13, 2014, 10:31:25 pm »
Nice game. But if you click it a lot of times it speeds up. And you can move the panel out of the screen. But besides that it looks fine.
Thanks for your comment but like I said I wasn't trying to actually make a good game. It's just a little introduction for my friend. If I were really trying it was old be much better. I'm aware of the bugs :p

12
Pretty much correct, Corrupted_Fear. It's supposed to be just one place where you can bring a project from start to finish. Come up with an idea, find inspiration, learn from others and ask questions, find trustworthy people, launch a project, work on it with team members in the workspace, and then have the site help get your project publicity. I came up with the idea because I realized how tough it was to get a team of dedicated people to help you with anything. Making a dream reality is more difficult than it should be right now, and we hope to change that.

Thanks for all the support :) It's been pretty tough trying to get this thing of the ground, and so many set backs have made it take longer than we've wanted. But I'm working with an awesome team of people who aren't giving up no matter what. Sometimes you just have to keep pushing through, even after two years :D For anyone who wants to help later, we will some day be asking on infinity.

As for the status of the website now...it's pretty much totally done, maybe even ready for beta, as far as code is concerned. The main issue is that people are pressed for time, and I've been having to make the new UI and designs for recently created pages. And I suck at those things. So, trying right now to fix this design problem we've always had. When we launch, the design will likely be actively changing. Actually, once alpha launches, we will be making tons of changes almost immediately to satisfy any issues you testers end up having with it. So regardless of how we launch we will come out of alpha strong.

Since I promised alpha by a certain date, and didn't meet it, I think ill be posting cool little facts and more information every once in a while in this thread, with updates. When alpha is ready, no sooner than the day it is ready, I will PM all people we will allow to participate. Anyone who doesn't get in at first will probably gradually be added on.

Thanks again guys! If anyone has any questions,  I'll try my best to answer everything.

13
Web Oriented Coding / Pong in JS [Tutorial, sort of]
« on: April 13, 2014, 12:42:05 am »
This is kind of sort of a tutorial on how to make pong in JS. My friend wanted to know how to make games, and so I thought I'd code up a quick example for him. The comments totally explain how everything works, and I thought it might be useful for any people here who wanted to know how simple games are made, but never quite understood how. Some things I explain are really basic, because my friend is quite new.

This game uses html5 canvas, and the basic principle is constantly updating data, and drawing things where the new data is after clearing the screen. I know this isnt the best possible way to do this, like i used set interval instead of request animation frame, and some other optimization stuff, but this is just a nice, easy to understand introduction that avoids those slightly more complex things, and gets you in the mind of a game dev.

 All you need to understand is javascript.

This is a fully working html page and you can just save it in a .html file and open it in a browser. Ask me if you have any questions :)

Also, is anyone interested in this kind of stuff? I've been planning on making some real tutorials soon.  I can make tutorials on anything html5: mobile apps/games, and websites. I might do some other things in the future as well but im thinking html5 tuts for now. Tell me what you guys want to see so I dont make useless things!

Code: (javascript) [Select]
<!-- This is what comments look like in HTML! -->
<!-- Tell the browser that we intend to use html5 technology like canvas -->
<!DOCTYPE html>
<html>
<head>
<title>Pong</title>
</head>
<body>
<!-- Add canvas element and give it an id so javascript can find it -->
<canvas id="game"></canvas>
</body>
<!-- Code for pong game -->
<script type="text/javascript">
//a function enclosed like this means that it runs automatically
//it's called an anonymous function because it doesnt have a name.
//wrap your code in these to prevent conflicts with any other code on
//this webpage
(function(){
//get the canvas element from the DOM
var canvas = document.getElementById('game');
//make the background of the canvas black
canvas.style.background = 'black';
//set height and width of canvas in pixels
canvas.height = 500;
canvas.width = 900;
//save the height and width of the canvas in variables for later use
var height = canvas.height;
var width = canvas.width;
//this is the variable we use to manipulate the canvas
var ctx = canvas.getContext('2d');
//set a font style for the entire canvas
ctx.font = '25px Sans';
//this array will store all of our previous scores so that
//we can later calculate high score
var scores = [0];
//initialize our current score to 0
var score = 0;
//this variable will hold our animation loop,
//we will use it to stop and restart our animation
//each time the loop runs we will update all of our data
//and then redraw everything in their new positions
var animLoop;
//this is our object for the ball
var ball = {
//remember, on canvas top left is (0, 0)
//so we make x and y one to make sure they dont start at the very edge
//or else our collision handler would catch it too soon
x: 1,
y: 1,
//set the width, height, and radius of our ball
width: 10,
height: 10,
radius: 10,
//x-velocity and y-velocity, how much does the ball move in each direction everytime
//our loop runs?
vx: 5, //5 looks like a decent speed
vy: 5,
//everytime our loop runs, we will add 5 to our current x and y positions,
//causing the ball to move. Each time the loop runs we will clear all
//old images of the canvas so we only see motion
update: function() {
this.x += this.vx;
this.y += this.vy;
},
//after updating, we now need to tell the canvas to draw in the required
//locations. So use the arc method to draw a ball
//using our current x and y positions, color, and radius data
draw: function() {
ctx.fillStyle = 'red';
ctx.beginPath();
ctx.arc(this.x, this.y, this.radius, 0, 2 * Math.PI);
ctx.fill();
}
};
//here's our object for the paddle
var paddle = {
//we want the paddle to be at the center of the screen, so
//width / 2 should accomplish that. however, we also need to compensate
//for the width of the paddle (or else only the left corner would be at the center),
//which I just decided would be width / 5.
//so move the paddle back by half of its width to compensate
x: width / 2 - (width / 5)/2,
//remmeber, in canvas coordinates, top left is (0, 0),
//so the bottom will be the height of the canvas.
//after that, we need to raise up the paddle by its height,
//so subtract 10
y: height - 10,
//the player will control our x-velocity, so initialize it to 0
//the paddle will not move up and down so no y-velocity is required
vx: 0,
height: 10,
//make sure the width of the screen is a fact or the paddle width
//so it always scales even if we increase canvas size
width: width / 5,
//same as ith update method of ball
update: function() {
this.x += this.vx;
},
//same as draw method of ball
draw: function() {
ctx.fillStyle = 'red';
ctx.rect(this.x, this.y, this.width, this.height);
ctx.fill();
}
};
//to get the heigh score...
var getHighScore = function() {
var highScore = 0; //have a variable to store our high score
//loop through of of our stored scores
for (var i = 0; i < scores.length; ++i) {
//if this score is bigger than 0 and alse more than the last score we looked at (i - 1)
//then set the high score to this score
if (i > 0 && scores[i] > scores[i - 1]) {
highScore = scores[i];
}
}
//give back the high score
return highScore;
}
//when this function runs our canvas will show "Click to play"
var beginScreen = function() {
ctx.clearRect(0, 0, width, height);
ctx.fillStyle = 'white';
ctx.fillText("Click to Play", canvas.width / 2.5, canvas.height / 2);
};
//stop the animation with clearInterval(), clear the screen, and then write "Game Over" With current hight score
//also store our current score into our array of scores, so we can see if its the new high one with
//getHighScore()
var endScreen = function() {
clearInterval(animLoop);
ctx.clearRect(0, 0, width, height);
ctx.fillStyle = 'white';
scores.push(score);
ctx.fillText("Game Over! Current high score: " + getHighScore(), canvas.width / 4, canvas.height / 2);
};
//what to do when objects collide (game logic here)
var handleCollisions = function() {
//this is called a rectangular collision algorithm
//returns true if objects
//collide within the bounds of their width and height
//and false otherwise. You may have to look at it for a bit to understand how this is calculated
//but its quite simple. Basically, seeing if the x and y positions are the same,
//while compensating for the width and height of both objects
var collides = function(a, b) {
//Just to clarify:
//a is the first object and a.x retrieves the "x" porperty of that object
return a.x < b.x + b.width &&
a.x + a.width > b.x &&
a.y < b.y + b.height &&
a.y + a.height > b.y;
}
//if the ball and paddle collide
if (collides(ball, paddle)) {
//add one to the score
++score;
}
//we dont need else ifs because these can all happen at once
//if the ball and paddle collide OR the ball is at the top of the screen
if (collides(ball, paddle) || ball.y <= 0) {
//reverse the balls trajectory. So when we hit the paddle go the opposite way,
//and when we hit the roof go the opposite way. In the Y direction of course
ball.vy = -ball.vy;
}
//if the ball is outside the left or right side of the screen
//remember, we have to use > and < and not just = because we are adding more than one to the
//positions each time. So sometimes it might be a bit past a boundary and we still want to catch that
if (ball.x <= 0 || ball.x >= width) {
//reverse the balls X trajectory so it doesnt cross boundary
ball.vx = -ball.vx;
}
//if the ball hits the ground, run the endScreen() function....
//YOU LOSE!!!
if (ball.y >= height) {
endScreen();
}
};
//call the update and draw functions on both our ball and paddle
var updateAndDraw = function() {
//update our data
ball.update();
paddle.update();
//clear the canvas so we only see new drawings
ctx.clearRect(0, 0, width, height);
//draw objects with new positions
ball.draw();
paddle.draw();
//now update our score counter with the current score
ctx.fillStyle = 'white';
ctx.fillText("Score: " + score, 10, 25);
//run handle collisions function each time
//to make sure our game knows when stuff hits
handleCollisions();
};
//whenever we start playing the game again, we need to reset all data to its defaults
//and make sure our current score for this game is once again initialized to 0
//and then we start our animation again with setInterval()
var startPlaying = function() {
ball.x = 1;
ball.y = 1;
paddle.y = height - 10;
paddle.x = width / 2 - (width / 5)/2;
score = 0;
//1000/60 means 60 FPS
//every time our loop runs call the function "updateAndDraw"
animLoop = setInterval(updateAndDraw, 1000 / 60);
};
//okay, document.addEventLister is a built in thing in JS
//where you listen to key and mouse events on the document
//so here, on every key down...
document.addEventListener('keydown', function(e) {
var key = e.keyCode; //what key is being pressed?
//you have to google or memorize certain key codes.
//they are easy to find and tell the computer which key is being pressed
//these numbers mean left or right
//change move the paddles based on player keys
//remember negative reverses direction
if (key === 37) paddle.vx = -5;
else if (key === 39) paddle.vx = 5;
});
//everytime a key is released...
document.addEventListener('keyup', function(e) {
var key = e.keyCode;
//if the key being released is the left or right one
//stop the paddle by making the velocity 0
if (key === 37 || key === 39) paddle.vx = 0;
});
//now, instead of listening for events on the document
//lets listen for events that happen to the canvas element
//the canvas variable was defined at the beginning
//whenever the canvas is clicked....
canvas.addEventListener('click', function(e) {
startPlaying(); //run the startPlaying() function to run the game
});
//immediately show the begin screen by calling the function on page load
beginScreen();
})();
</script>
</html>
<!--
And that's it bro. That's how you make pong in JS. The concepts are actually pretty simple,
and just build on concepts you already understand. Try playing aroud with some values to see what happens.
You could try fixing some bugs, adding a paddle to the top as well, adding more balls,
making the player be able to get certain powers, etc.
Have fun!
-->

14
Hello guys, just a quick update.

We were planning on rolling out the alpha on Sunday, but some issues came up and things will be delayed for a short time. I hate not meeting deadlines, but I'll keep you guys updated on the situation. Alpha is still very close. All this means is that when we release it there will be more for you  to enjoy.

I dont want to get too much into exactly what happened, but there was some disagreement around how exactly we should launch. Also, so far everyone who's posted here will be invited for the alpha when it comes up :)

I'll be back within the week for updates. I apologize for the setback, but stuff like this can be tough. However, I think you guys will like what you see when you see it!

15
Thanks guys! Those PM's are coming soon, and will contain lots more information. I really appreciate all of you who encouraged this project, and especially those who joined the team. Relax and Jeremy have been especially awesome for sticking with it, despite all the various issues we had along the way. It's totally insane to have something you've worked on for so long finally about to launch.

And yes, Factionwars, I invite you to hack the site :D I think we've been pretty thorough with security, but I guess it's time to find out ;)

Lucid, don't worry about it. Just the fact that you and others joined encouraged us to keep going. :)

Pages: [1] 2 3 ... 18