Hi !
Featured games (84)
games approved by the League of Dukes
Games in Showcase (604)
Games in Android Showcase (171)
games submitted by our members
Games in WIP (653)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1] 2 3 ... 10
 on: 2015-08-03 04:41:32 
Started by BurntPizza - Last post by wessles
I was super excited at the beginning of today.

Spent the entire day trying to get the steamworks API working with RFLEX, with very little success. First, libGDX refused to import SteamPuppy properly; I unfortunately gave up on it after a few hours of screwing around with gradle. Then I found steamworks4j, which libGDX accepted without any fuss. However, for some reason, I couldn't set any achievements and stats. The information request method insisted the connection to Steam's server was a success, but the callback showed that it had failed. No matter how much I messed with it / googled for a solution, nothing came up. That took up the rest of my day.

I'm pretty disappointed at my lack of progress here. To be fair, I never really expected wonderful support for Java in steam's API.

On the bright side, yesterday I made a drunk-mode (reverse controls) for RFLEX:

<a href=";hl=en_US&amp;start=" target="_blank">;hl=en_US&amp;start=</a>
Side note: is there a gfycat integration for SMF?

So I guess that's nice. Hopefully tomorrow will turn out better (i.e. people will answer my forum questions).

tl;dr: Smiley Clueless Cry ... Undecided


 on: 2015-08-03 04:20:40 
Started by KevinWorkman - Last post by noctarius
My HTTP  Long-Polling system works slightly different. I know users logged in into the game, so I collect updates until the next requests comes in (normally you always have a connection, in practice reconnection might need a few millis). The connection knows it's userid and some special session key (so that nobody can hijack a players session).

For suspending the long-polling sockets I use Jetty continuations or the new Servlet 3 features and create an async context. That returns the underlying thread back to the pool until I need the socket to send results back. Most often I anyways don't really have to hold them for a long time since game content is highly changing but it heavily depends on the game what the update rate is.

To send events to the server (the second connection) the server immediately responds with an event id the client can wait for in the long-polling events.

 on: 2015-08-03 04:13:12 
Started by theagentd - Last post by theagentd
Ohhhh!!!! Thank you!

One thing though, I want to delete all files that have a .new version of them and replace them with the new version. I don't want to keep the .old ones. Also, does this script recursively process all subfolders as well?

 on: 2015-08-03 03:59:59 
Started by theagentd - Last post by CaptainJester
This seemed to work for me.
#copy all files that match any file with the .new extension. Copy the existing files without the .new to .old
find . -type f -name '*.new' | sed 's/\(.*\)\.new$/\1/' | xargs -I '{}' mv {} {}.old
#copy all the .new files removing the .new extension
find . -type f -name '*.new' | sed 's/\(.*\)\.new$/\1/' | xargs -I '{}' mv {}.new {}

Make sure the file you put it in you make executable with chmod +x or whatever filename you choose.

find . -type f -name '*.new'
#Find starting in the current directory (.) files (-type f) with the name (-name) ending with .new ('*.new')

#sed matches stream input to produce output
sed 's/\(.*\)\.new$/\1/'
#pipe the stream to sed. The '/' is used as a delimeter. The 's' says that this is a substitution. '\(.*\)\.new$' is a regular expression to find any line that ends in new. The '\1' says to output the first group which is the file name without new.

xargs -I '{}' mv {} {}.old
#xargs allows you to pass lines to an executable command. mv is the move command. Basically the same as rename.

 on: 2015-08-03 03:59:27 
Started by BurntPizza - Last post by chrislo27
This is one of many apple cider vinegar traps I laid out.[/img]

Out of sheer curiosity, is it just apple cider vinegar inside that cup? Do they drown in vinegar or is there something else?

 on: 2015-08-03 03:55:25 
Started by BurntPizza - Last post by Archive
Fruit fly infestation.

This is one of many apple cider vinegar traps I laid out. This one is located in the living room. Sorry for potato quality.

That image makes me happy because I hate flies.

 on: 2015-08-03 03:44:24 
Started by BurntPizza - Last post by tom_mai78101
Fruit fly infestation.

This is one of many apple cider vinegar traps I laid out. This one is located in the living room. Sorry for potato quality.

 on: 2015-08-03 03:03:10 
Started by EliwoodL - Last post by chrislo27
Your WorldMap would have a list of Regions. Each Region has a list of Rooms and Connections between rooms. This is your current design, and it should work pretty well for what you want.

Think of each Region as a universe. The WorldMap has a lot of universes. The universes don't interact with each other, but they're all in an area where they're contained.

The Regions are universes. Each one has Rooms and Connections. Think of Rooms as galaxies and Connections as a wormhole found in the centre of each galaxy. Each wormhole can only go to one galaxy, but they you can potentially have multiple wormholes to multiple galaxies.

I don't know if that space analogy helped. I hope it did Grin

EDIT: more detail below

Rooms could be generic. They get rendering data from its region (so a brick wall theme for castles, etc.). Connections would do the same. You could also make rooms unique and have subclasses of Room for each rendering type that implement an abstract rendering method for different designs. You can also customize each room (different traps, loot) and make it more immersive that way.

 on: 2015-08-03 03:02:04 
Started by theagentd - Last post by theagentd
After much work I've come up with this little bat script. It checks all files in the same folder (and all subfolders) for files that have the ".new" extension and overwrites the old files using move commands.

@echo off

echo Checking directory...
call :updateFiles

echo Starting updater!
java -jar updater.jar

exit /b


for /R %%f in (*.new) do (
    move "%%f" "%%~nf"
    echo Updated %%~nf!

for /D %%d in (*) do (
    cd %%d
    call :treeProcess
    cd ..

Now to do the same using an .sh script...  Emo

 on: 2015-08-03 02:26:48 
Started by unlight - Last post by unlight
Thank you for the quick reply!

I am using Java and just to clarify further, I have a Content class which I use at the start of my game to store each of my images as a final static variable, then when I create an entity I will set its image as below.

public entity() {
    this.image = Content.entityImage;

I hope / don't imagine that there would be any copying that I am unaware of using this method.

I have seen people using a hash map as a way to manage their content which I will look into later if it is a better option.

Pages: [1] 2 3 ... 10
SHC (28 views)
2015-08-01 03:58:20

Jesse (20 views)
2015-07-29 04:35:27

Riven (40 views)
2015-07-27 16:38:00

Riven (22 views)
2015-07-27 15:35:20

Riven (24 views)
2015-07-27 12:26:13

Riven (15 views)
2015-07-27 12:23:39

BurntPizza (36 views)
2015-07-25 00:14:37

BurntPizza (46 views)
2015-07-24 22:06:39

BurntPizza (31 views)
2015-07-24 06:06:53

NoxInc (37 views)
2015-07-22 22:16:53
List of Learning Resources
by gouessej
2015-07-09 11:29:36

How Do I Expand My Game?
by bashfrog
2015-06-14 11:34:43

List of Learning Resources
by PocketCrafter7
2015-05-31 05:37:30

Intersection Methods
by Roquen
2015-05-29 08:19:33

List of Learning Resources
by SilverTiger
2015-05-05 10:20:32

How to: JGO Wiki
by Mac70
2015-02-17 20:56:16

2D Dynamic Lighting
by ThePixelPony
2015-01-01 20:25:42

How do I start Java Game Development?
by gouessej
2014-12-27 19:41:21 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!