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.


Topics - wakeboarderCWB

Pages: 1 2 3 [4]
46
Creations / Java Programs
« on: October 14, 2011, 06:14:51 PM »
Well I'm getting into Java so I decided to post some of my work here. They're usually small applications such as a basic calculator, but as time progresses they will become more advanced and use multiple classes and methods.

Basic Calculator
Asks the user for two numbers and stores them in the variables num1 and num2. Then it adds the two and displays the answer.
Code: (java) [Select]
import java.util.Scanner;

public class Think{
public static void main(String[] args){

Scanner userInput = new Scanner(System.in);

double num1, num2;

System.out.print("Please enter the first number: ");
num1 = userInput.nextInt();

System.out.println();

System.out.print("Please enter the second number: ");
num2 = userInput.nextInt();

double userAnswer = num1 + num2;

System.out.println("The answer is " + userAnswer);


}
}


Angle Identifier
Asks the user to input a measurement of an angle in degrees. Then it will take that measurement and classify it as acute, obtuse, straight or right.

Code: (java) [Select]
import java.util.Scanner;

public class Main{

public static void main(String[] args){

Scanner userInput = new Scanner(System.in);
double angleDegree;
String angleType = "Please enter a degree.";

System.out.print("Please enter the degree of the angle: ");
angleDegree = userInput.nextDouble();

System.out.println();

if (angleDegree == 90)
angleType = "Right";
else if (angleDegree > 90)
angleType = "Obtuse";
else if (angleDegree < 90)
angleType = "Acute";
else if(angleDegree == 180)
angleType = "Straight";

System.out.println("The angle is " + angleType);
}
}


Switch Statement Tester
Asks the user to input 1, 2 or 3. Then it will output a line depending on what they entered. The switch statement is basically an alternative to the if-statement.

Code: (java) [Select]
import java.util.Scanner;

public class Main{
public static void main(String args[]){

Scanner userInput = new Scanner(System.in);
int input;

System.out.print("Please enter 1, 2, or 3: ");
input = userInput.nextInt();

System.out.println();

switch(input){
case 1:
System.out.println("You entered one!");
break;
case 2:
System.out.println("You entered two!");
break;
case 3:
System.out.println("You entered three!");
break;
default:
System.out.println("Please enter 1, 2 or 3!");
break;
}
}
}


Craps Game
You roll two dice. Each die has six faces, which contain one, two, three, four, five and six spots, respectively. After the dice have come to rest, the sum of the spots on the two upward faces is calculated. If the sum is 7 or 11 on the first throw, you win. If the sum is 2, 3 or 12 on the first throw (called “craps”), you lose (i.e., the “house” wins). If the sum is 4, 5, 6, 8, 9 or 10 on the first throw, that sum becomes your “point.” To win, you must continue rolling the dice until you “make your point” (i.e., roll that same point value). You lose by rolling a 7 before making your point.

Code: [Select]
import java.util.Random;

public class Craps{

private static final Random diceRoll = new Random();

private enum GameStatus{ CONTINUE, WON, LOST };

public static void main(String args[]){
int playerPoint = 0;
GameStatus gameStatus;

int sumOfDice = rollDice();


switch (sumOfDice){
case 7:
case 11:
gameStatus = GameStatus.WON;
break;
case 2:
case 3:
case 12:
gameStatus = GameStatus.LOST;
break;
default:
gameStatus = GameStatus.CONTINUE;
playerPoint = sumOfDice;
System.out.printf("Roll again. Your current point is: %d\n", playerPoint);
break;
}

while (gameStatus == GameStatus.CONTINUE){
sumOfDice = rollDice();

if (sumOfDice == playerPoint)
gameStatus = GameStatus.WON;
else if (sumOfDice == 7)
gameStatus = GameStatus.LOST;

if (gameStatus == GameStatus.WON)
System.out.println("Player has won! :D");
else if (gameStatus == GameStatus.LOST)
System.out.println("Player has lost. :(");
}
}

public static int rollDice(){
int rollOne = 1 + diceRoll.nextInt(6);
int rollTwo = 1 + diceRoll.nextInt(6);

int sum = rollOne + rollTwo;

System.out.printf("You rolled a %d and %d with the sum of %d.\n", rollOne, rollTwo, sum);

return sum;
}
}


47
Creations / Deathrun Gamemode(Name Yet to be Decided)
« on: May 06, 2011, 07:06:08 PM »
    Name soon. Suggestions are open. I am also taking new logos.


    Information
    Deathrun, which has no official name yet, is an arcade style deathrun gamemode being developed by wakeboarderCWB. I plan to expand the name "Deathrun" in Garry's Mod to make the gamemode more fun. I will be adding more features, and a less evil theme.


    What's Planned?
    Well, I am sure you want to know what I have planned, so see the list below.

    • Shop System. Buy hats, player models, trails, and even effects.
    • An arcade theme. Bright, catchy colors, along with arcade music.
    • An easy way to add new hats, player models, trails, effects, and map stuff for those who host the gamemode.
    • Voting system for maps with map logos(optional).
    • One model for death. A player's custom model will not be used for this team.
    • More to come soon...



    Progress
    The gamemode is still in early development. I am only coding the base part, but I enjoy doing it. I will update this section with my progress as I move further along.

    • Teams
    • Picking player's team system. Sets team based on certain conditions, otherwise it's random.



    Media
    I will post pictures/videos here. Stay tuned...



    Gamemode Codes
    I will post codes on how to add new items for the shop, maps, etc here. Stay tuned...


    Feel free to comment below. Ask me any questions, suggest a name or logo for the gamemode, or point out anything you don't like or wish to be added.[/list]

    48
    General Discussion / Fast 5 Discussion
    « on: April 30, 2011, 10:09:24 PM »
    This is a serious discussion. Any posts that are deemed to be related to "Postwhoring" or "Trolling" will be removed.

    If you like surprises and have not seen this movie, you should not read my review.

    Well, I just got back from seeing Fast 5 in IMAX. I really enjoyed the movie, it caught my attention. Although it had a few fake parts, the movie, in my opinion, was one of the best Fast and Furious movies. The one part I really didn't like is when they were pulling the safe with two Dodge Chargers. There is no way they can pull the safe out of the wall, and through town, toppling it over cars and through a bank. They don't have enough traction, nor horsepower. The fight between Vin Diesel and The Rock was amazing, bloody, and extreme. Overall, the movie was great, besides $5.25 for a soda...

    49
    General Discussion / Sony PSN Personal Info Stolen
    « on: April 26, 2011, 05:24:26 PM »
    Thank you for your patience while we work to resolve the current outage of PlayStation Network & Qriocity services. We are currently working to send a similar message to the one below via email to all of our registered account holders regarding a compromise of personal information as a result of an illegal intrusion on our systems. These malicious actions have also had an impact on your ability to enjoy the services provided by PlayStation Network and Qriocity including online gaming and online access to music, movies, sports and TV shows. We have a clear path to have PlayStation Network and Qriocity systems back online, and expect to restore some services within a week.

    We’re working day and night to ensure it is done as quickly as possible. We appreciate your patience and feedback.

        Valued PlayStation Network/Qriocity Customer:
        We have discovered that between April 17 and April 19, 2011, certain PlayStation Network and Qriocity service user account information was compromised in connection with an illegal and unauthorized intrusion into our network. In response to this intrusion, we have:

            Temporarily turned off PlayStation Network and Qriocity services;
            Engaged an outside, recognized security firm to conduct a full and complete investigation into what happened; and
            Quickly taken steps to enhance security and strengthen our network infrastructure by re-building our system to provide you with greater protection of your personal information.

        We greatly appreciate your patience, understanding and goodwill as we do whatever it takes to resolve these issues as quickly and efficiently as practicable.

        Although we are still investigating the details of this incident, we believe that an unauthorized person has obtained the following information that you provided: name, address (city, state, zip), country, email address, birthdate, PlayStation Network/Qriocity password and login, and handle/PSN online ID. It is also possible that your profile data, including purchase history and billing address (city, state, zip), and your PlayStation Network/Qriocity password security answers may have been obtained. If you have authorized a sub-account for your dependent, the same data with respect to your dependent may have been obtained. While there is no evidence at this time that credit card data was taken, we cannot rule out the possibility. If you have provided your credit card data through PlayStation Network or Qriocity, out of an abundance of caution we are advising you that your credit card number (excluding security code) and expiration date may have been obtained.

        For your security, we encourage you to be especially aware of email, telephone, and postal mail scams that ask for personal or sensitive information. Sony will not contact you in any way, including by email, asking for your credit card number, social security number or other personally identifiable information. If you are asked for this information, you can be confident Sony is not the entity asking. When the PlayStation Network and Qriocity services are fully restored, we strongly recommend that you log on and change your password. Additionally, if you use your PlayStation Network or Qriocity user name or password for other unrelated services or accounts, we strongly recommend that you change them, as well.

        To protect against possible identity theft or other financial loss, we encourage you to remain vigilant, to review your account statements and to monitor your credit reports. We are providing the following information for those who wish to consider it:

        U.S. residents are entitled under U.S. law to one free credit report annually from each of the three major credit bureaus. To order your free credit report, visit www.annualcreditreport.com or call toll-free (877) 322-8228.

        We have also provided names and contact information for the three major U.S. credit bureaus below. At no charge, U.S. residents can have these credit bureaus place a “fraud alert” on your file that alerts creditors to take additional steps to verify your identity prior to granting credit in your name. This service can make it more difficult for someone to get credit in your name. Note, however, that because it tells creditors to follow certain procedures to protect you, it also may delay your ability to obtain credit while the agency verifies your identity. As soon as one credit bureau confirms your fraud alert, the others are notified to place fraud alerts on your file. Should you wish to place a fraud alert, or should you have any questions regarding your credit report, please contact any one of the agencies listed below.

        Experian: 888-397-3742; www.experian.com; P.O. Box 9532, Allen, TX 75013
        Equifax: 800-525-6285; www.equifax.com; P.O. Box 740241, Atlanta, GA 30374-0241
        TransUnion: 800-680-7289; www.transunion.com; Fraud Victim Assistance Division, P.O. Box 6790, Fullerton, CA 92834-6790

        You may wish to visit the web site of the U.S. Federal Trade Commission at www.consumer.gov/idtheft or reach the FTC at 1-877-382-4357 or 600 Pennsylvania Avenue, NW, Washington, DC 20580 for further information about how to protect yourself from identity theft. Your state Attorney General may also have advice on preventing identity theft, and you should report instances of known or suspected identity theft to law enforcement, your State Attorney General, and the FTC. For North Carolina residents, the Attorney General can be contacted at 9001 Mail Service Center, Raleigh, NC 27699-9001; telephone (877) 566-7226; or www.ncdoj.gov. For Maryland residents, the Attorney General can be contacted at 200 St. Paul Place, 16th Floor, Baltimore, MD 21202; telephone: (888) 743-0023; or www.oag.state.md.us.

        We thank you for your patience as we complete our investigation of this incident, and we regret any inconvenience. Our teams are working around the clock on this, and services will be restored as soon as possible. Sony takes information protection very seriously and will continue to work to ensure that additional measures are taken to protect personally identifiable information. Providing quality and secure entertainment services to our customers is our utmost priority. Please contact us at 1-800-345-7669 should you have any additional questions.

        Sincerely,
        Sony Computer Entertainment and Sony Network Entertainment


    Tl;Dr: If you have a PlayStation Network account, all of your information on the account has been stolen by a hacker.

    http://blog.us.playstation.com/2011/04/26/update-on-playstation-network-and-qriocity/

    50
    General Discussion / VIP Giveaway Contest!
    « on: April 16, 2011, 10:25:07 PM »
    Congratulations to...

    Owencobs

    Applications are currently: CLOSED
    Donations are currently: CLOSED

    Winner will be picked Monday, April 25th, 2011. If, for some odd reason, the date needs to be changed, I will let you know.



    Thanks to Rogi, this contest is possible. Rogi is doing a GMR/HRP Cash -> VIP transaction, which is how the VIP will be given.


    The Contest

    The contest is very simple. I wanted to make the contest as equal as possible, so what I came up with is a simple essay of why you should recieve the VIP. I didn't want to do a build contest, GMR contest, or anything else because some people have faster cars in GMR, or have better wire skills than others. An essay is a simple, easy way to win the VIP. If you would like to apply, follow these steps:

    • Make sure applications are open(Check top of thread for status).
    • Please only apply if you will actually be active in the community.
    • PM ME your application with this format:
    Code: [Select]
    [b]Steam Name: [/b]

    [b]SteamID: [/b]

    [b]Age: [/b]

    [b]How long have you been with Catalyst-Gaming?: [/b]

    [b]Have you had any bans with Catalyst-Gaming? If so, how long and why?: [/b]

    [b]Which servers do you play on(GMR, HRP, HL2RP)?: [/b]

    [b]Do you promise to follow ALL server rules?: [/b]

    [b]Why should you be chosen to recieve VIP([i]2 Paragraphs, MINIMUM[/i])?: [/b]

    Your application will be looked at, and saved until the very end of the contest. I will gather 2 more judges to judge who will win.


    Donating

    I will be handing $125,000 GMR over to Rogi for the donation. I am currently accepting donations, GMR cash only, which will go toward the CONTEST ONLY. I will not scam you, as that would be incredibly stupid and immature. If you would like to donate, find me in-game or PM ME this application filled out:

    Code: [Select]
    [b]Steam Name: [/b]
    [b]Donation amount: [/b]
    [b]When are you usually on the server?: [/b]

    Seeing as the give command is broken, and VIP only, I will be using my admin powers to take the money from you, and give it to me. PLEASE MAKE SURE YOU HAVE ENOUGH CASH TO DONATE.


    Thanks To...

    I would like to thank the following people for donating and/or helping me with the contest.

    Rogi - Donating for VIP

    Currently, there are no GMR cash donators. When someone donates, their name will appear in this section.


    If you would like to see the benefits of recieving VIP, head to the "Donate" tab at the top of the website.
    You may post any questions and/or suggestions for this contest in this thread.

    51
    Media / Country/Southern Rock
    « on: April 16, 2011, 08:47:18 AM »
    I'm sure there are a few people here that like country or southern rock.

    Southern rock is a subgenre of rock music, and genre of Americana. It developed in the Southern United States from rock and roll, country music, and blues, and is focused generally on electric guitar and vocals. Although it is unknown from where the term southern rock came, "many people feel that these important contributors to the development of rock and roll have been minimized in rock’s history."

    Country music (or Country and Western) is a blend of traditional and popular musical forms traditionally found in the Southern United States and the Canadian Maritimes that evolved rapidly beginning in the 1920s.[1] Distinctive variations of the genre have also emerged elsewhere including Australian country music.

    I'm more of a southern rock kind of guy, but there are still some good country songs. My favorite singer is probably Jason Aldean, but I have others such as Blake Shelton, Toby Keith, Billy Currington, and some more.

    Media
    <a href="https://www.youtube.com/watch?v=isLqoB3v_wI" target="_blank">https://www.youtube.com/watch?v=isLqoB3v_wI</a>

    <a href="https://www.youtube.com/watch?v=DkS5H3Of4-E" target="_blank">https://www.youtube.com/watch?v=DkS5H3Of4-E</a>

    <a href="https://www.youtube.com/watch?v=OvyTY_oYR_c" target="_blank">https://www.youtube.com/watch?v=OvyTY_oYR_c</a>

    <a href="https://www.youtube.com/watch?v=al2DFQEZl4M" target="_blank">https://www.youtube.com/watch?v=al2DFQEZl4M</a>

    <a href="https://www.youtube.com/watch?v=PKpQRjj_WbU" target="_blank">https://www.youtube.com/watch?v=PKpQRjj_WbU</a>

    <a href="https://www.youtube.com/watch?v=XtMy5IBmX7E" target="_blank">https://www.youtube.com/watch?v=XtMy5IBmX7E</a>

    <a href="https://www.youtube.com/watch?v=JTT2LEyjdC4" target="_blank">https://www.youtube.com/watch?v=JTT2LEyjdC4</a>

    More to be added soon.

    52
    Introductions / wakeboarderCWB
    « on: January 29, 2011, 07:55:03 PM »
    Hey all,
    My name is wakeboarderCWB. I have never played on any of your servers yet, but look forward to. I know quite a bit of you from other communities. I like to wakeboard, as you can see in my name, and also I like to code gamemodes. ATM, I am actually coding my own RP gamemode. It is still in it's early stage, but I plan to get a lot done with it. Glad I can see a lot of old friends, and even meet new ones here.

    Sincerely,
    wakeboarderCWB

    Pages: 1 2 3 [4]
    SimplePortal 2.3.7 © 2008-2024, SimplePortal