Jump to content
Sign In to follow this  
Tropod

RH Menus

88 posts in this topic Last Reply

Highlighted Posts

Posted:
Last Online:  
 

Would it be possible to get our hands on the source code?
Or would that be a very big mistake to do?

Just wondering about it, so don't blame me for thinking about a solution! 12.gif



Greetz Thunderm@n

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 
we can't get our hands on the source code unless someone miraculously converts 6 million lines of assembly to nice C++ language... and that ain't happening sometime soon.
 
in the meanwhile, this thread was dead for a reason... if someone ever feels the need to revive it with some usefull info, that would be nice but there's no need to ask for any prgress when there is nothing said in a month...

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 
Date: 7/10/2005 3:58:44 PM Author: ArkenbergeJoe

Hallo. Greetings from Germany

Here is my new menu. Has problems thereby. See the screen.
Menuhttps://www.simtropolis.com/idealbb/files//Schaltfl

Share this post


Link to post
Share on other sites
Posted:
Last Online: A long, long time ago... 
 

No, it is a totally new menu - the ferry menu is below the airport menu, and it is cut off by the photograph.

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

heh why  did he post when nobody has psoted in 1 year?42.gif

Share this post


Link to post
Share on other sites
Posted:
Last Online: A long, long time ago... 
 

I think adding a new menu button is easier than to place items inside the custom menu because the menu positions of the icons depend on OccupantGroups and it's impossible to add and configure new OccupantGroups without decompiling simcity.exe, modifying ingreds.ini and recompiling it.



File in german:

Akte = a booklet with sheets of paper inside
Datei = file on a disc


Edit: Can you please try to move the two lightrail puzzle piece icons of the new menu?

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 
The new menu is erzeuegt by a UI file.  However one cannot register any ID number there, then nothing is called, but one, which existed times and one out-commentated possibly somewhere.  This menu (by the bus to irritate do not leave) should, believes I, times a separate underground menu to become.  (see Button ID in the copy file, this number have I taken) there are still several dead ID's.
--Translated by Google--
Das neue Men

*:) Here are my assets of STEAM Workshop *;)

...and my Thread at Spielerheim.de (german language)

Share this post


Link to post
Share on other sites
Posted:
Last Online: A long, long time ago... 
 

If we can do something with that, I think the best way is to split the misc network menu into a lightrail menu (tram, subway and el-railway related items) and a street traffic menu (bus and toll booth related items)

Ich denke, falls man mit dem Men

Share this post


Link to post
Share on other sites
Posted:
Last Online: A long, long time ago... 
 

It looks like if the menus are configured by these LUA-scripts:

GID: 0x4A5E8EF6
IID: 0xFF048A3E



network_tool_types = {}

network_tool_types.ROAD = hex2dec('8c329937')
network_tool_types.RAIL = hex2dec('00000029')
network_tool_types.HIGHWAY = hex2dec('00000031')
network_tool_types.PIPE = hex2dec('2992f72c')
network_tool_types.SUBWAY = hex2dec('299237bf')
network_tool_types.POWER_LINE = hex2dec('00000032')
network_tool_types.STREET = hex2dec('ea6e379d')
network_tool_types.HIGHWAY_INTERSECTION_BASE = hex2dec('6a470000')
network_tool_types.HIGHWAY_INTERSECTION_LIMIT = hex2dec('6a47ffff')
network_tool_types.AVENUE = hex2dec('2b730c5b')
network_tool_types.ELEVATED_RAIL = hex2dec('2b79e398')
network_tool_types.MONORAIL = hex2dec('4be099de')
network_tool_types.ONEWAY = hex2dec('0be099c1')
network_tool_types.DIRT_ROAD = hex2dec('2be099a9')
network_tool_types.GROUND_HIWAY = hex2dec('0be0998f')
network_tool_types.HIWAY_RAMP = hex2dec('6a472090')


IID: 0xFF263B45


tutorial_buttons.kButtonPlaceElevRail = 0x2b79e398

Share this post


Link to post
Share on other sites
Posted:
Last Online:  
 

Iactually, that's just a definition, not a configuration... all those numbers are probably hardcoded somewhere else (or maybe if we're lucky somewhere in an exemplar).

you see, all they're doing here is just equaling network_tool_types.ROAD to hex2dec('8c329937') so whenever they have to use the button for the road network type somewhere in the LUA code (for example, a link in a news message that gives you the road network button when clicked) they can just say something like call_network_button(network_tool_types.ROAD) instead of call_network_button(hex2dec('8c329937')). Obviously the second is easier to make mistakes with and harder to debug.

Share this post


Link to post
Share on other sites
Posted:
Last Online: A long, long time ago... 
 

I realized that and did not find out a way to make use of the menu. For the NON-Plop-Building items, a SubmenuType-declaration in it's exemplars is used. (value: 0, different submenu-types for each menu). The transit-network menus started with IDs at 0x4000. I tried out values up to 0x400F but that did place an item to the new menu.

Share this post


Link to post
Share on other sites
Posted:
Last Online: A long, long time ago... 
 

UI files illustrate all the GUI stuff in simcity like menus and dialogues. It is something comparable with HTML. Graphics, texts and widgets are placed, variables are displayed and clicking a button calls an event.

Adding content to the menu is possible by an exemplar setting of the menu button configurations. The problem is that it's an hexadecimal number with a range of 0000:FFFF. There are 65536 possibilities and only one may match except something else may be an hint.

The ID if the road, rail, highway, misc network, power and water menus start at 0x4000 but no unused it around 4000 matches for this custom menu.

Other menus like zone, park and landmark menus have a completely different value.

Share this post


Link to post
Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     
    GoaSkin:
    What would you suggest use if not google or altavista? I learnt German many many years ago, but have since forgotten most of it.
    That list you posted, while it is on some level actual game code, it isn't really used as far as these particular menus go. The file that contains that information is used for the Advisors.

    ArkenbergeJoe
    Thanks for the file 2.gif. I will take a look at it. It may be possible to somehow make use of it. May be, may be not. I must say it is certainly interesting to see button functionality there 2.gif. I think all you would need to figure out is a comparable SubMenuKey value, &/or a comparable OccupantGroup menu value that will work.



    AB files are different from UI files. AB files are related to UDI Sounds. AB files have got nothing to do with UI files or menus. But since these are not fully decoded, not all of them can be accounted for in this respect.

    As far as menus go, the first post in the thread explains how this works for Menus containing Lots. As for menus other than Lots; most of the UI related Exemplars themselves, like the Road Tool Exemplar, contain the actual keys themselves & shouldn't need explaining. This is some older posts of mine laying about somewhere that explain some of them in more detail (but not much). Essentially though (this is without modds); each menu that contains a Networking/Zoning/Terrain tool (this includes the Powerline & Pipe tool), typically the first Tool in that menu is actually attached to the whole menu, thus providing a linking mechanism that makes those particular menus possible. Removing the attached tool from the menu actually causes the game to crash if you attempt to access the menu. Least this was the case pre-RH, but I dare say not much has changed in this respect with RH. The different SubmenuKey* properties are secondary in nature & are associated with the particular menu for which the key is for. But the linking tool needs to exist in the proper menu still.


    EDIT:
    I found it. This is Pre-RH & pretty old so some information will not be relevant, but hopefully it gives you some idea perhaps regarding those menus containing networking/zoning/terrain tools:
    3rd & 5th post of mine down:
    Reader Exemplar Properties

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online: A long, long time ago... 
     
    @Tropod: I realized that the LUA files don't contain helpful information.

    To add icons to the menu, we need to find out an unknown exemplar setting (a parameter ID which represents the unknown submenuKey for this menu). This parameter is not in order with the other (known) network submenuKeys.

    Share this post


    Link to post
    Share on other sites
  • Original Poster
  • Posted:
    Last Online:  
     

    As I've already mentioned, a comparable SubMenuKey or OccupantGroup value will need to be found in order to be able to place anything in the menu.
    Come to think of it, it will most likely be an OccupantGroup Value, namely because the game does not crash when the button/menu is accessed. So I dare say, that it was intended to be used as a Menu containing Lots, not networking tools, despite using the ElevatedRail ButtonID (see post above & first post in this thread). So any experimenting with possible OccupantGroup values should be done with a Lot.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online: A long, long time ago... 
     

    I will try out a few ranges of OccupantGroups and SubmenuKey values. If someone could give me an hint, it would go faster.

    Tried out: SubMenuKey 4000:403F -> no success

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    no offense Goaskin, but I wouldn't try too long... if the ID is somewhere up high (in the 0xEA###### range for example) you'd be searching for a few hundred years :P

    I wouldn't be surprised if there's a list of all these somewhere... and a list of all the ones that can be used... this list is possibly (well most likely) in the .exe though, so we'll probably need a few tricks to get it.
    It's also possible there's some sort of a system in the numbers, a system we're not seeing yet... I think it can't be a coincidence several numbers are around 4000, several start with EA and several with 6A...

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online: A long, long time ago... 
     

    As far as I know, the network-related IDs are around 4000. Other things have a SubmenuKey smewhere else. The HEX-IDs of the submenuKeys seem to be nowhere else in simcity1.dat. Neither an ASCII search, nur a (reverse) binary search showed hits. The ingreds.ini also doesn't contain information about that but OccupantGroups to try out.

    Isn't it possible to ask Maxis for an hint? I read in older threads that there are people with connections.

    I haven't tried to extract resources from the simcity binary using resource grabber tools.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online: A long, long time ago... 
     

    I tried to add all possible OccupantGroup numbers to a lot exemplar by writing a rudimentary program to do that.

    - not more than 4908 reps were possible (OccupantGroups 0x0-0x132B)
    - the game seems only to read out a small number of REPs


    It does not seem to be possible to find out the OccupantGroup to use by trying.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    So what are you saying? Will it be possible eventually? Or are you still working on it?

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online: A long, long time ago... 
     

    It is hard to find out usable OccupantGroups or SubmenuKeys for placing items into these menus by examining the threads while running the game. The unknown values are nowhere used in the game.

    Share this post


    Link to post
    Share on other sites
    Posted:
    Last Online:  
     

    @GoaSkin:

    Ich hab dir mal eine UI mit 8 Buttons gebaut. Leider werden sie im Spiel nicht aufgerufen. 26.gif Die beiden UIs mit je 7 Buttons aber werden ohne Probleme dargestellt. 42.gif
    Dabei ist mir aufgefallen, dass kein Menu mehr als 7 Buttons hat. Ich werde da mal weiter expermentieren.
     
    translate by babelfish (exeptionally)
    I for you times a UI with 8 Buttons built. Unfortunately they are not called in the play. The two UIs with 7 Buttons each however are represented without problems. It noticed to me that no more menu has than 7 Buttons. I become there times expermentieren far.
     

    *:) Here are my assets of STEAM Workshop *;)

    ...and my Thread at Spielerheim.de (german language)

    Share this post


    Link to post
    Share on other sites

    Sign In or register to comment...

    To comment in reply, you must be a community member

    Sign In  

    Already have an account? Sign in here.

    Sign In Now

    Create an Account  

    Sign up to join our friendly community. It's easy!  

    Register a New Account

    Sign In to follow this  

    • Recently Browsing   0 members

      No registered users viewing this page.

    ×

    Thank You for the Continued Support!

    Simtropolis depends on donations to fund site maintenance costs.
    Without your support, we just would not be in our 24th year online!  You really help make this a great community. *:thumb:

    But we still need your support to stay online. If you're able to, please consider a donation to help us stay up and running. This helps sustain a platform where we can share our community creations for years to come.

    Make a Donation, Get a Gift!

    Expand your city with the best from the Simtropolis Exchange.
    Make a Donation and get one or all three discs today!

    STEX Collections

    By way of a "Thank You" gift, we'd like to send you our STEX Collector's DVD. It's some of the best buildings, lots, maps and mods collected for you over the years. Check out the STEX Collections for more info.

    Each donation helps keep Simtropolis online, open and free!

    Thank you for reading and enjoy the site!

    More About STEX Collections