• Welcome to the new COTI server. We've moved the Citizens to a new server. Please let us know in the COTI Website issue forum if you find any problems.
  • We, the systems administration staff, apologize for this unexpected outage of the boards. We have resolved the root cause of the problem and there should be no further disruptions.

World Lookup

After reading you post I did a quick Google search and if I understand what I found it seems that there is now a File API for HTML5 that would allow me to do read/write files from the local machine.

There is no unfettered file access to the local system. You can use <input type=file multiple> to allow selection of files to make available to script (read-only). File writes are limited to download actions.

Chrome did define a "sandboxed" virtual file system but that didn't get traction with other browser vendors. There is a standardized database API that can persist files. (Caveat: it's pretty buggy in Safari)

And that there seems to be one for JavaScript as well. Is that correct?

Without getting too pedantic: HTML is a markup language, and the HTML specification defines that language and provides hooks JavaScript to interact with it via DOM and places for other specifications such as the File API to plug in. So "as well" is nonsensical. It's all one big hairball, where "HTML5" is really a marketing term and reality is spread across multiple specs.

Disclaimer: Making this all suck less is literally my day job. I'm manager for (and engineer on) the team at Google that implements "storage" APIs for Chrome, as well as an editor on some of the Web Platform specifications.

So... I can answer some questions here. :)
 
Disclaimer: Making this all suck less is literally my day job. I'm manager for (and engineer on) the team at Google that implements "storage" APIs for Chrome, as well as an editor on some of the Web Platform specifications.

So... I can answer some questions here. :)

That's actually pretty cool, and explains why TravellerMap.com is so awesome. :)

There is a standardized database API that can persist files. (Caveat: it's pretty buggy in Safari)

So as long as I use a database instead of files, it should work. Of course anyone who has an Apple device will probably want to install an alternative browser such as Chrome to avoid any potential issues. Where is this API documented? Or what is it called?

And I assume that database I should use is SQLite.

So much to learn.... This should be fun!
 
So as long as I use a database instead of files, it should work. Of course anyone who has an Apple device will probably want to install an alternative browser such as Chrome to avoid any potential issues. Where is this API documented?

Sadly, on iOS you don't have the ability (c/o Apple's policy) to install separate browser engines. Chrome and other browser apps on iOS are forced to use the Safari engine (WebKit) internally, which means they can't add that sort of functionality. *major sigh*

The database API is Indexed DB. Warning: the learning curve is rather steep. (I'm the spec editor on it. In my defense, it was like that when I joined the project...) Rather than spamming this thread, hit me up via email. (@gmail)
 
Love it, but not fully working

First, let me say that I love the sheet and am really glad you kept it open to editing. That makes it really easy to enter my own system data.

I'm using the included system data and I can't figure out why it won't display the images. I can follow the generated links and they work fine. Can anyone point me in the right direction? Any help is much appreciated. New to traveller and this site, so be gentle.
 
First, let me say that I love the sheet and am really glad you kept it open to editing. That makes it really easy to enter my own system data.

I'm using the included system data and I can't figure out why it won't display the images. I can follow the generated links and they work fine. Can anyone point me in the right direction? Any help is much appreciated. New to traveller and this site, so be gentle.

I am so glad you like it!!

In order for the images to be displayed you must have an active internet connection. If you do and it is still not working, make sure that the links are building correctly.
 
This is incredible. Thank you very much!

I recently went through Pirates of the Drinax and had thoughts of converting it to another location. This could make that a real possibility! Much obliged!
 
Unfortunately, this does not work for me... :-) Whenever I try to pull up a new world it has me stuck on Aeoya. Am I missing something?

Thanks!
 
Java seems like a good option for your use case. If you really are serious about cross-platform, working with one eye on the Oracle ADF framework spec looks like a decent starting point. You shouldn't need to actually develop on or target iOS first, but it would help ensure you carefully separate out the core logic and UI components, which would be useful discipline when it comes to any platform porting exercise. You can probably use a cross-platform Java desktop UI framework to support Windows, OSX and Linux, but when it comes to mobile you'd probably have to re-develop the UI for each from scratch.

I'm not sure that going cross-platform on mobile will be worth it if you have a cross-platform desktop solution though. There can't be all that many Traveller fans who might want to use this that don't have access to at least one of these desktop platforms.

Simon Hibbs
 
This has turned out to be THE thing that I have been trying to find/create/hack for the past couple years. A place to store and call up all the UWP data, Library Data, and my Ref data for a world with a single click. To bloody organize a sandbox style Traveller game for an entire sector or larger. Realmsworks was too much work. This has turned out to be the BOMB.

DickNervous has completely sold this short by indicating it is for the Drinax campaign. What it is, is a template that can be used to input any sector data and turn it into the ultimate campaign guide for your own use.

A big thanks to Dick, who has spent the past five days helping me figure out how to do exactly that. I rebuilt the data range to draw from the Glimmerdrift (Milieu990) set from Traveller map and it works like a dream. Now I have a complete campaign reference tool just awaiting my input.

I highly recommend folks take a look at this as a General tool and not just for Drinax. It is eminently hackable to conform to your campaign's needs.

And I learned how to create/edit/display Traveller Map code. So now I can contribute!

I’m like a kid with a nice, shiny new knife…
 
Python GUI required?

Python in NetBeans IDE. Hope this is useful.

https://www.youtube.com/watch?v=QsfnhJ-ABDc

Install NetBeans8.2 (current version, though Python runs from 8.02 onwards)

also shows other versions possible in video (I haven`t tried yet)

Rules.py runs and generates UWP details with Jython2.7!

Your code rocks!

Create new Project (select category Python & file JySwing.py)

Code below is copy of GUI created as JySwing.py

You should be able to figure the rest (I`m still learning).

///////////////////////////////////////////////////////////////////////////////////////


Code:
"""DO NOT REMOVE THIS HEADER

BSD License: http://www.opensource.org/licenses/bsd-license.php

Copyright (c) 2008, Sun Microsystems, Inc
All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:

1.Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.

2.Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation and/or
 other materials provided with the distribution.

3.Neither the name of the Sun Microsystems, Inc nor the names of its contributors may
be used to endorse or promote products derived from this software without
specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

"""


# Demonstrate usage of Java Swing classes in Jython

from java.awt import BorderLayout
from javax import swing

__author__ = "Amit Saha <amitksaha@netbeans.org>"
__date__ = "$29 Nov, 2008 12:59:25 AM$"


class SimpleFrame():

    def __init__(self):
        """We shall create the JFrame with a label and a button"""
    print "Initializing"

    def draw(self):


        #Create a JFrame and add a label, button and a menu bar
        self.frame = swing.JFrame("Hello Swing from Python", visible=1 )


        # a JLabel
        self.label = swing.JLabel("This is a Swing app in Jython")


        # a JButton
        self.button = swing.JButton("Click me!")
        

        # Adding a action
        self.button.actionPerformed = self.ClickBtn


        self.frame.contentPane.add(self.label, BorderLayout.CENTER)
        self.frame.contentPane.add(self.button, BorderLayout.SOUTH)

        self.frame.defaultCloseOperation = swing.JFrame.EXIT_ON_CLOSE;

        self.frame.pack()

    


    def ClickBtn(self, event):
        """handle button click"""

        self.label.setText("Clicked!")


if __name__ == '__main__':
    frame = SimpleFrame()
    frame.draw()
 
Profound apologies

:eek:
I think I have mixed up posts. Sorry for confusion.

:)
DickNervous` sheets will come in very handy. Thanks for the effort!

Like it lots.
 
Back
Top