logo
 drop

Main

Community

Submissions

Help

96250496 visitors

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - creeperton

Pages: [1] 2 3 4 5 6 ... 14
1
I like the look of it. Has the feel of an industrial control panel where you have all of the switches and knobs and levers right there in front of you. Seeing everything out in the open like that is cool. Anyone here ever worked with an Alesis Micron? Exact opposite: Menu Hell.
That's what I intended.  I labeled the unknown bytes and bits too.  No reason not to, eventually someone will figure out what they're used for or someone will make a hack that uses them.

2
This is what I mean by layouts:

https://docs.oracle.com/javase/tutorial/uiswing/layout/visual.html

I'm having trouble putting keys and values in the hashmap that holds the item data.  You can't have methods larger than 64 KB.  I can't hardcode loading these values into the data structure because there isn't enough room to load it all.  I need to read it from a file but file I/O is the one thing we haven't really covered yet (granted, we barely covered most of the requirements for this project because the book sucks, but learning everything else has been easier than the specifics of I/O in java).

3
My instructor said that it's fine to open source it, provided I do so after final grades are posted.

I have a question about scope and GUI objects.  How do methods - specifically the methods called by action listeners - write to objects when those objects are outside of their scope?

https://i.imgur.com/oSU6XOA.png

The Combo Box with the "Item:" label (it shows "00: Cure" right now) should change the state of every other GUI object on the page each time a new item is selected - it should do this to reflect the data structure that contains each item entry.

The other GUI objects on the page should change the data structure of the current item entry when they are changed.

Should I put all these objects and action listeners in the same method, then call that method in the constructor to create the items JPanel, and add it to the overall GUI?  Should I put them in a separate class - maybe one that extends JPanel?  Which is the best design choice for future maintainability?  How will I ensure that the program overall can access the items data structure - is it as simple as get/set methods?

4
Here's what I have so far:
https://i.imgur.com/ygHxJdP.png

Every time a user selects a different item int the top-left combo box, the rest of the GUI in this tab needs to be updated to reflect the entry in the item data table for that item.  What should I google to learn more about this?

The GUI isn't done yet, by the way.  I need to finish the rest of the elements and then make a good looking layout.  Just to check, a JPanel is roughly equivalent to a div tag in HTML5, right?

I think I'll have a dictionary/map that where the key is the item name (a string) and the value another dictionary/map that is all of the bytes for that item's entry in the item data table.  That way when I need to read from it, I input the item name and then the index of the byte I want to get, and I have a bunch of switch case statements and whatnot for updating the gui elements that represent the state of that item's entry.  When I want to write to it it's the same, except when I'm only writing a single bit in which case I need to do a bit of math.

Does this sound sane?  I could also do it with an array (or an array of arrays) but I want to do it in the easiest possible way to maintain and focus on performance once I have all the features I want.

This is my final project for CS 162.  I'm only implementing editing for 2 tables in the game and file I/O for the SCUS (Playstation 1 executable) file.  Eventually this project will encompass much more than what's covered in CS 161 and 162, so how long should I wait before I release the source code?  Am I allowed to release the source code?  Do I own the copyright on this program if I turn it in as an assignment?  If I don't, then how am I supposed to develop a portfolio that I can host on my github account?  Should I just not bring it up and hope that it will be to much of a POTA for them to worry about when/if they do learn about it?

5
Site Talk / Utility gives an error when I try to access it.
« on: March 15, 2015, 07:05:27 am »

6
How do you do this?  I couldn't figure it out.

I understand how to make a dictionary, what it is, how to add entries to it, and so on, but I don't know why it isn't iterable by index or at least by the first and subsequent entries (an Iterator object should work fine, but it doesn't).  What gives?  Who made such an arbitrary decision?  What's the point in having maps if you can't iterate over the damn things?  What were the java designers smoking?

On a related note, I never realized how being a lazy piece of shit could make me a good programmer.  I helped a classmate in the library today and she said that she was impressed with what I did.  I didn't try to be smart - I tried to avoid doing things manually as much as possible so I could waste time on the internet.  Should I keep up the laziness or should I make an attempt to work harder?

7
Wow this is great!  Thank you both!

Quote
They deal with files extracted from isos instead of full roms, so it might not be what you're looking for. Some of them might require that you read documentation about the structure of the files.
I have to deal with ISOs on PS1 games, it's perfect.

Quote
My programming is lazy, very inefficient most of the time and I know for sure that some stuff is plain wrong (in some of the MXP programs at least), but I think the code is pretty easy to follow and can be used as an introduction to Swing. You might be more interested in getting started with JavaFX though, considering it's becoming the new standard.
We learn Swing in the next class, so that works for me.

8
I want something to study.

This is mostly for my own interests, but farting around with an open source rom hacking tool will help me in school.

9
General Discussion / Coupling and orthogonality
« on: February 24, 2015, 02:46:24 am »
Could someone explain how coupling relates to orthogonality in OOP?

10
I don't actually need the function to accept user input and use that input to generate code that will append the specified element to the end of the specified list.  I was just overachieving and I bit off more than I could chew.  I also thought it would be easier in the long run if I had code I could copy and paste, while changing only the user prompts and the list methods.

11
I'm trying to make a function that will append an item to a list based on user input.  Python 2.7.8, Windows 7.

Code: [Select]
# Lab 4.1 Create five separate lists.  Each list should have a theme and the
# theme should be reflected in the list name and its elements.  Examples are:
# pets = ['dog', 'cat', 'rat']
# numbers= [34, -1232, 456, 2134]

weather = ['Clear','Rain','Snow','Storm','Windy','Hail','Fog']

locations = ['Park','Forest','Beach','River','Library','Cafe','College',
'Apartments','Home']

actions = ['Walk','Examine','Activate','Talk','Wait','Eat','Sleep','Read',
'Think','Choose']

day = ['Morning','Mid-day','Afternoon','Evening','Twilight','Night',
'Late Night','Dawn']

animals = ['fish','Crow','Deer','Seagull','Mosquito','Racoon','Skunk',
'Cougar']

# Lab 4.2 Using the lists you defined in 4.1, define functions that
# demonstrate your knowleldge of the list functions: append, extend,
# remove, pop, index, sort, and reverse.  Write at least 2 examples
# using each function.

def listAppend():
    listName = raw_input('You choose to append an item to a list.\nFirst we'
    ' must select a list.\nType the name of one of these lists to see its'
    ' elements:\nweather, locations, actions, day, or animals.\n'
    'Which list do you want to view? ')
# ^get name of list to append an element
    if listName == 'weather':
        for i in weather:
            print i
    elif listName == 'locations':
        for i in locations:
            print i
    elif listName == 'actions':
        for i in actions:
            print i
    elif listName == 'day':
        for i in day:
            print i
    elif listName == 'animals':
        for i in animals:
            print i
# ^print all the elements in the selected list
    else:
        print 'There is no list available under that name!'
# ^print if user mistypes name of list
    appendElement = str(raw_input('Please type the element you wish to append to'
    ' the selected list: '))
# ^get the element user wants to append to list
    newList = listName + '.append(\'' + appendElement + '\')'
    eval(newList)
    print newList

listAppend()
The prompts work fine but the output is:
Code: [Select]
Please type the element you wish to append to the selected list: Sandstorm
weather.append('Sandstorm')

What am I doing wrong?

I guess what I want to do is use input to get parts of code and then execute that code.  I know that it's a really stupid idea because that means that users can execute code but still you'd think there would be a way to concatenate string literals and variables that are also strings together and then execute them as code.

12
Programming / Re: Python libraries for FF7 LZSS compression?
« on: October 24, 2014, 10:27:48 pm »
Holy shit.

13
Programming / Python libraries for FF7 LZSS compression?
« on: October 23, 2014, 08:00:21 pm »
Taking my first programming language class, using Python 2.7.8.  For my final project I want to make a tool that does the following:
1. Opens a file (BATTLE.ARC),
2. Splits it into 3 parts:
* The parts before a certain point,
* The parts at a certain point (which are actually a compressed file called BATTLE.OUT), and
* The parts after a certain point.
3. Decompresses the second portion of that file (BATTLE.OUT),
4. Patches locations in the BATTLE.OUT,
5. Compresses BATTLE.OUT, and
6. Reassembles BATTLE.ARC from the first part of the file, the second part (compressed BATTLE.OUT), and the third part.

Here's an archived forum post which indicates that FF7 LZSS is different from Haruhiko LZSS.
http://forums.qhimm.com/index.php?topic=2317.5;wap2

For later versions of this tool I'd like to load the patches from xml in plain text files, patch a *.bin/cue disc image directly, and make it a GUI tool but I probably can't do that for the due date of the final project so they're on hold.

14
Site Talk / Re: Submission questions
« on: September 28, 2014, 06:44:59 pm »
How do I update a patch?

https://www.dropbox.com/s/vi8ebulb4utl1zx/MagicOnly.zip?dl=0

I fixed some errors in my Magic Only mod for SaGa Frontier, but I don't see any dialog for removing the old patch and uploading this one.

15
Gaming Discussion / Re: Vagrant Story Graphics Hack Released.
« on: September 09, 2014, 01:45:23 am »
Done.

16
Newcomer's Board / Re: Need help with Snes/Chrono Trigger hacking
« on: September 08, 2014, 10:07:47 pm »
You're not the first person to come up with this idea!

There are plenty of people who can and probably will help you here before long.

17
Gaming Discussion / Re: Nice
« on: September 07, 2014, 10:43:55 pm »
I'll miss staring at Ashley's leather man-thong and assless chaps. :'(

18
Site Talk / Re: Submission questions
« on: September 07, 2014, 10:42:21 pm »
Is it possible to edit the summary/description I made for a patch?  I forgot to include a few I wrote and just threw some crap together before I remembered.

19
Just try changing the '40' in the bytes I posted with '00'. It may seem strange, but those bytes are really where it loads the instruction from, not the uncompressed data from BATTLE.OUT.

I'm guessing it's part of BATTLE.ARC (took a guess and looked in this file). Hmm, looks like there's compression. Until this is figured out, try to avoid any of the codes that patch memory after 0x180000.
Sorry, don't know. I tend to resort to placing files in a ZIP with no compression and searching through it for the hex, then searching/scrolling up to find the name. Knowing the LBAs of all the files are would probably help.
Bolded portion is brilliant.

Also from what you said it sounds like at least part of battle.out is reproduced in battle.arc - maybe battle.out is redundant.  Wouldn't surprise me, SaGa games are like that.

I have python scripts for dealing with ARC files (one to split them into their subfiles, another to read the starting addresses of each of their subfiles), it's less of an issue than you think.

LBA refers to the starting location of the file in a disc image?

I had issues trying to grab data from the SaGa Frontier 2 disc image because data tables would be split by large chunks of apparently random shit.  Are the chunks of random shit of a standard size?  If they are then I can generate starting addresses of each file in the disc image using a spreadsheet.

I'm sorry I'm asking so many questions!

Edit:
Compression is standard Haruhiko compression. You can use one of the LZS tools for FF7/FF8.
I'll check at Qhimm, thanks for all your help!

20
Site Talk / Submission questions
« on: September 05, 2014, 09:39:29 pm »
Does ROM/ISO Information refer to the patched file or the unpatched file?


Pages: [1] 2 3 4 5 6 ... 14