Java Hangman game with source code – my first game :-)

Share This: Written back at university my first Java game. Maybe not last ;] https://github.com/cann0nf0dder/java/tree/master/Hangman Please include me in your references if you copy any part of the code.User Guide: Source Code:

 
Continue reading…

 

Java Network Programming Buyer/Seller Telnet Application

Share This: SellConnection class: package buyersellerprogram.server; import java.net.Socket; import java.io.IOException; import java.io.BufferedReader; import java.io.InputStreamReader; import java.io.InputStream; import java.io.OutputStream; import java.util.StringTokenizer; import buyersellerprogram.bargainer.Seller; public class SellConnection extends Thread { Socket connection; Seller seller; public SellConnection(Socket s, Seller sellerIn) { //** Set the value of the Socket to s connection = s; //** Set the value of […]
Continue reading…

 

Flex emulating sh terminal

Share This: private function keyHandler(event:KeyboardEvent):void { if(event.keyCode == Keyboard.ENTER){ // variable to hold user input var command:String = userInput.text; // variable to read from output and keep history var history:String = console.text; // variables to create shell like enviroment var root:String = “root@LB:~# “; var rootchanged:String = “root@LB:”; var i:int = 0; // cd command […]
Continue reading…

 

Java IpAddressLookup simple class

Share This: import java.net.*; import java.util.*; public class IpAddressLookup { public static void main(String[] args) { try { System.out.print(“Please enter the address : “); Scanner Sc = new Scanner(System.in); String host= Sc.next(); InetAddress PC = InetAddress.getByName(host); String hostname = PC.getHostName(); byte[] signed = PC.getAddress(); System.out.println(“Hostname is : ” + hostname); System.out.println(“Signed address is ” + […]
Continue reading…