Author Topic: Soldat Admin Java Applet  (Read 9208 times)

0 Members and 1 Guest are viewing this topic.

Offline iDante

  • Veteran
  • *****
  • Posts: 1967
Soldat Admin Java Applet
« on: August 03, 2008, 06:51:55 am »
Soldat Admin Applet
by iDante (with very minor help from the dude that wrote SARJ)

This is a veery simple admin program, the only reason it could be of any use to anyone is that it can be embedded in websites with the following steps:

1. Add Admin.jar to your website.
2. Add this code to where you want it to appear (don't change width, be careful with height):
Code: [Select]
<APPLET code="SoldatAdmin.class" archive="Admin.jar" width="800" height="400">

I really just made this to learn how to do some things in java (threads, sockets, more advanced GUI's), so I don't really plan on adding much more to it.
« Last Edit: August 05, 2008, 04:32:38 am by iDante »

Offline ManSoft|Warlord

  • Major
  • *
  • Posts: 70
  • Soldat.IDE Creator
Re: Soldat Admin Java Applet
« Reply #1 on: August 03, 2008, 06:56:39 am »
n1! I did something like that in PHP: http://soldatadmin.soldatnet.de/ :D

€dit: Maybe you should mask the password with "*" ;)

Offline iDante

  • Veteran
  • *****
  • Posts: 1967
Re: Soldat Admin Java Applet
« Reply #2 on: August 03, 2008, 07:03:40 am »
€dit: Maybe you should mask the password with "*" ;)
I could... but java doesn't have an automatic thing to do that like HTML :P

Right now it only refreshes when you hit the Refresh button or type REFRESH into the command thing... should I make it so that whenever a message is sent to the client it should refresh (only one line of code)?

Offline ManSoft|Warlord

  • Major
  • *
  • Posts: 70
  • Soldat.IDE Creator
Re: Soldat Admin Java Applet
« Reply #3 on: August 03, 2008, 07:42:35 am »
for the refresh-thing: Try to do it as a thread :D with a delay(5000)-procedure:

Code: [Select]
import java.lang.Thread;

public class ThreadSleepDemonstration {
public static void main(String[] args) {
System.out.print("Hello");
try {
Thread.sleep(2000);
} catch (InterruptedException e) {} // nichts
System.out.print(" World!");
}
}

Offline iDante

  • Veteran
  • *****
  • Posts: 1967
Re: Soldat Admin Java Applet
« Reply #4 on: August 05, 2008, 04:32:19 am »
Critical error fixed
Turns out that java applets can't set up sockets to other servers than the ones they're on. I didn't notice this when making it because I used a local dedicated server to test it.
The only way to get around this is to "sign" the applet, AKA put it in a .jar and make whoever is using it say "OK" that it will set up a connection to another server before the applet even loads.

Also, the code to include it in html is updated.

Offline kefoo

  • Major(1)
  • Posts: 32
  • Kefoo from POLAND
Re: Soldat Admin Java Applet
« Reply #5 on: August 22, 2008, 06:55:07 am »
Wooooohooo, nice program. Did you really do it ?
"...So am I still waiting
For this world stop hating
Can't find the good reason
Can't find hope to belive in..."

Offline miketh2005

  • Soldat Beta Team
  • Flagrunner
  • ******
  • Posts: 668
  • What's the URL for www.microsoft.com?
Re: Soldat Admin Java Applet
« Reply #6 on: September 20, 2008, 07:22:39 pm »
You know what would be way cool? Make something like this, but for regular players, that way you can put it on your site like a lil shout box thingy, and talk to the players playing in the server :D It would be super super super super fun. You should make it so that the color is the server is Blue, and it says the username that they imput in the java applet.
Quote from: 'Ando.' pid='12999178' dateline='1309046898'
My new password is secure as shit :)
Mate, I am not sure Shit is even secured nowadays.

Offline omerstart

  • Major(1)
  • Posts: 7
Re: Soldat Admin Java Applet
« Reply #7 on: March 19, 2011, 03:39:47 am »
great program :)
look at my site;
http://soldat.turkforumpro.com/t25-soldat-admin-program-online#25
thx iDante but I think the bigger thing .  Soldat mobile phone program .  I work will begin .
Screen size 320 * 240  and will be supported java .  Thanks again
« Last Edit: March 19, 2011, 03:51:35 am by omerstart »