Sillysoft
Steam users, please help Greenlight Lux Delux!
Sillysoft Forums
Forums Of Universal Domination 
Games
About - FAQ
Download - Buy
Lux Delux
Maps - Rankings
Download - Buy
Castle Vox
Maps - Rankings
Download - Buy
Forums
Join the Forums
Log in - Memberlist
  RSS feeds  
Art - Wiki
News - Search
Random Map Generater plug-in interface

 
Post new topic   Reply to topic    Sillysoft Games Forum Index -> Features
View previous topic :: View next topic  
Author Message
rip
Lux Newbie


Joined: 31 Mar 2004
Posts: 353
Location: Vienna Austria

PostPosted: Wed May 26, 2004 10:02 am    Post subject: Random Map Generater plug-in interface Reply with quote

Sorry Dustin, just treating this as your to-do list. Laughing

I've got my map generator really working now, in its hacked-together, it-works-but-I-couldn't-explain-why, don't-breath-on-it, 1.0 version.

Time to rewrite it in Java, but I need an interface to write it to. Kin aw git one?

And while I would like to get a pane in the pref's panel for allowing the user to make adjustments to the output, it might be easier to give it a set of defaults that generate maps based on certain limited selections (a la small/medium/large on the current random map generator). In fact, I'll implement it for -s [small|medium|large] at the command line now.

Short term, an internal method for calling it from the command line would be sufficient for testing.

perl /path/to/mapgen.pl - -s [s|m|l]

The single dash (-) tells the script to output the luxboard to stdout.
The -s [s|m|l] tells the script to use standard, default configurations for a [s]mall, [m]edium or [l]arge board size.

Much luck on your Windows launch, and Mercy buckets!

rip
Back to top
View user's profile Send private message Visit poster's website View rip's ranking
dustin
Lux Admin
Lux Admin


Joined: 15 May 2003
Posts: 9134
Location: Vancouver

PostPosted: Wed May 26, 2004 4:59 pm    Post subject: Reply with quote

Yeah, I am sorry I've been such a deadbeat. However, the moral of the story is "keep bugging and you get what you want".

LuxMapGenerator.java - The java interface you must implement to create a map generator for Lux.
MapLoader.java - You will need this stub to compile your generator.

Consider this a beta, so your suggestions are welcome. I have re-jiggered my map generator to use this interface, so support for others inside Lux isn't far off. This interface could also be used to simply invoke a perl script as well. You don't have to rewrite it in java if you don't want to.
Back to top
View user's profile Send private message Send e-mail Visit poster's website View dustin's ranking
dustin
Lux Admin
Lux Admin


Joined: 15 May 2003
Posts: 9134
Location: Vancouver

PostPosted: Wed May 26, 2004 5:05 pm    Post subject: Reply with quote

Also, the email address you specified for this forum has been bouncing back reply notices for a day or so.
Back to top
View user's profile Send private message Send e-mail Visit poster's website View dustin's ranking
rip
Lux Newbie


Joined: 31 Mar 2004
Posts: 353
Location: Vienna Austria

PostPosted: Thu May 27, 2004 2:39 am    Post subject: Reply with quote

dustin wrote:
Also, the email address you specified for this forum has been bouncing back reply notices for a day or so.


That's odd. My mail server's log doesn't show anything with that address making it that far.

I just sent a test message to lux_forum@, and it worked. The 'Net is user-friendly. It just picks its own friends.

rip
Back to top
View user's profile Send private message Visit poster's website View rip's ranking
dustin
Lux Admin
Lux Admin


Joined: 15 May 2003
Posts: 9134
Location: Vancouver

PostPosted: Thu May 27, 2004 10:20 pm    Post subject: Reply with quote

This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

lux_forum@...
SMTP error from remote mailer after initial connection:
host A.secondary-mx.co.uk [217.169.20.13]: 450 Temporary unavailable - try later:
retry timeout exceeded
Back to top
View user's profile Send private message Send e-mail Visit poster's website View dustin's ranking
rip
Lux Newbie


Joined: 31 Mar 2004
Posts: 353
Location: Vienna Austria

PostPosted: Fri May 28, 2004 6:54 am    Post subject: Reply with quote

dustin wrote:

host A.secondary-mx.co.uk [217.169.20.13]: 450 Temporary unavailable - try later:


Ah haaaaah. Yes. My ISP has its good points (they own the domain "www.sod.ms") and its bad points (their servers are woefully underpowered or in a constant state of 'improvement')

rip
--
For the non-English speaking, 'sod' is British English, short for 'sodimize'. The rest you can figure out on your own :>
Back to top
View user's profile Send private message Visit poster's website View rip's ranking
rip
Lux Newbie


Joined: 31 Mar 2004
Posts: 353
Location: Vienna Austria

PostPosted: Mon Jun 07, 2004 2:53 am    Post subject: Reply with quote

Sorry, Dustin, you've made an assumption about the level of Java expertise that I have.

You assumed I had some. Rolling Eyes

I can't make heads or tails of what I'm supposed to do to implement the plug-in random map generator class.

Similarly, you called my 'bot a bozo (didn't place all his armies...what a bozo), and them's fighten' words. Eventually, I'll figure out all these little peculiarities, and then watch out. 2014, probably.

Anyway in order to make this less a rant and more a plea for info,

1) The 'seed', the 'unique value' that 'identifies a map'. Do you mean that if I pass a unique value to the generator, it should generate a specific (as opposed to a stochastic) map, regardless of the host machine involved? So if a player joins a network game that I'm hosting, you pass their client the id, and it generates the same map (and thus won't need to clog bandwidth by sending the map itself)? Or is it just a way for ensuring 99.999% probability that you don't overwrite a saved map with a generated one...

2) How do you make a callout to the underlying system from within Java, and read back the response from stdin? I'm not sure what the JVM security policies allow, or even what the specific code would be. The Java guy here at work is off at a certification class, or I'd ask him.

3) You might consider implementing the java 'external map generator' class for 'us', which would show how the internals of the class work without exposing your actual random-map class code to the world. That way, those of us who work in other languages can use what we know, and simply follow the protocol rather than learn an entirely new language.

4) Are there any blatantly incorrect assumptions here (remember, I Am Not a Java Guy):

In method 'generate', I would

loader.setBoardSize(ScrWid, ScrHei);
loader.setLoadText("What happens if I push this button?")

// generate map structures here...
// ...

// output the map
// do I need a <?xml ...> ident?

out.println("<luxboard>");
for(int i = 0; i < continents.length; i++)
{
out.println("<continent>");
// etc countries etc
out.println("</continent>");
}

etc for lines, etc.
}

5) Do I need to call anything to manage the printwriter? (ie, out.close, out.flush)

Thanks for your time!

rip
Back to top
View user's profile Send private message Visit poster's website View rip's ranking
dustin
Lux Admin
Lux Admin


Joined: 15 May 2003
Posts: 9134
Location: Vancouver

PostPosted: Mon Jun 07, 2004 3:10 pm    Post subject: Reply with quote

I am putting together a package with all the info required, along with some samples. I will try and put out a first draft of it today...
Back to top
View user's profile Send private message Send e-mail Visit poster's website View dustin's ranking
dustin
Lux Admin
Lux Admin


Joined: 15 May 2003
Posts: 9134
Location: Vancouver

PostPosted: Mon Jun 07, 2004 6:15 pm    Post subject: Reply with quote

OK, a package has been made available. It is a MapGenerator that uses a perl script to do the work. You can customize it to use any script. I posted the link in a new thread in the 'Map making...' forum. Let's continue the conversation there.
Back to top
View user's profile Send private message Send e-mail Visit poster's website View dustin's ranking
Display posts from previous:   
Post new topic   Reply to topic    Sillysoft Games Forum Index -> Features All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Meowzers Action Cats is our newest feline fun mobile game. Romp with cute cats on your phone and tablet.

Castle Vox is a simultaneous-turns team strategy boardgame. Diplomacy meets Axis & Allies game.

Lux Delux is an advanced Risk world domination game with over 800 maps, hard AI, and online multi-player.

American History Lux takes you through the wars of USA history. — Ancient Empires Lux spans Babylon to the Roman Empire.

Lux Touch, Lux USA and Lux DLX let you conquer the world on your iPhone, iPod, and iPad.

Sillysoft makes games for Mac OS X, Windows XP/Vista/7 and Linux. Also mobile games for iPhones, iPads, and iPod Touch.

Macintosh users may be interested to see our favorite Mac OS X games. For the full Sillysoft empire check out the sitemap.

Because taking over the world is fun.
                                 - Lux