enderwiggin / hafen-client Goto Github PK
View Code? Open in Web Editor NEWThis project forked from dolda2000/hafen-client
New Haven client
License: Other
This project forked from dolda2000/hafen-client
New Haven client
License: Other
Haven & Hearth Client This client is used to connect to the server for the Haven & Hearth online game and play said game. For details regarding the game itself, please refer to its main website at <http://www.havenandhearth.com/>. This file exists mainly to describe various technical aspects of the source tree. Getting a copy In case you are reading this README outside of a local copy of the source tree and wish to obtain one, the main way of doing so is by using the Git Version Control System. The public (read-only) repository is accessed via the following Git URL: <git://sh.seatribe.se/hafen-client> Build process In order to compile the source tree into a useful executable, the Apache Ant build system is needed. Running `ant' reads the `build.xml' file in the root directory of the source tree and performs the actions described by it to produce the executable output. There are two main outputs from the build process: * The `build/hafen.jar' file is the main executable, but executed in that environment, it is not configured to connect to the official server, and by default it does not have the data files necessary to execute properly; rather, it is intended for local development against a local server, with locally supplied data files, and so if you are coming to this project with the intent to connect to the official server, this will not be what you are looking for, rather: * The `bin' directory contains a copy of the above described `hafen.jar', but along with all the data files and configuration needed to connect to the official server. It can be executed with no further configuration (as with `java -jar bin/hafen.jar') and should work just like downloading the client from the main site. In order to remove intermediary compilation artifacts and other dynamic state and return the source tree to a supposedly pristine state, the `ant clean' target can be run. There may exist cases of incompatible changes where doing so may be necessary in order for the source tree to properly recompile. They should be rare, but if you are stuck on some hard-to-explain compilation or run-time issue, please try it before giving up. External dependencies The main external dependencies of the source tree are having a local Java Development Kit (JDK) installed, and (as mentioned above) the Apache Ant build system. On a Debian-based Linux system, these can usually be installed via the `default-jdk' and `ant' packages. For other distributions or operating systems, please use local documentation or your own faculties. Other than that, the client also requires the Java OpenGL implementation (JOGL), and also some data files from the main website. By default, the initial build process will download these dependencies from the main website into the `lib/ext` directory of the source tree. Once downloaded, they will not usually be updated, or even checked for updates, so subsequent runs should not depend on network access. If you want to supply your own local version of JOGL, you can do so by putting its files directly into `lib/ext/jogl' and ensure that the `lib/ext/jogl/has-jogl' file exists. As long as it does, the build system will not try to overwrite any JOGL files. Contrarily, in order to have the build system update JOGL to the latest version from the main website, the `lib/ext/jogl/has-jogl' file can be manually removed. Please note that running `ant clean' will remove the entire `lib/ext' directory, and so will both update JOGL from the main website and remove any local copy of JOGL that you may have supplied. Cursory source tree overview The vast majority of files constituting the source code of the client reside in the `src/haven' directory. Given that standard Java directory structures tend to devolve into a bit of a dumping-ground of files of small and large relevance alike, some points of particular interest may be useful, as follows. * MainFrame.java contains the main() function executed when running the client normally. It constitutes the main window of the client and starts everything running in it. * Config.java loads all runtime configuration and handles any system properties, command-line arguments and the like to modify said configuration. * JOGLPanel.java constitutes the main AWT component for running and rendering the game, and also contains the main-loop and all the event-dispatching machinery. * Session.java handles the fundamentals of the main game protocol and maintaining the connection to the server. * Resource.java is used to load any data not part of the source code itself, such as images, textures, audio clips, 3D models, &c&c. * Widget.java contains the base class of all the UI widgets in the client. Formatting style * Indentation is done in blocks of 4 columns. * The Tab character (ASCII 9) is used in the classical and only correct way: It advances the cursor to the next column ordinal divisible by 8. It does not advance the cursor by 8 columns, and it most certainly does not advance the cursor by 4 or 2 columns. If you use an IDE, you may want to check your settings on that one, because they are often wrong. * Line endings are neither Mac style (CR) nor Windows style (CRLF), but Unix style (LF). * Last but not least, I'm not extremely particular about naming, but if it's one thing that I really dislike, it is camelCase. If you wish me to accept back any modifications you may make, you will certainly increase your chances of acceptance by avoiding it. Thank you! Contributing back If you want me to accept back any changes that you might have made into the public client available from the website, the one main rule that we wish to enforce is that we want you to sign over ownership of the code you wish to contribute to us. That may seem draconian to some, but please keep in mind that it is fairly common, being practiced not least by the FSF, and it is too important for us to not lose ownership of future development to forgo. Generally, we would consider the code as owned by us as long as the copyright notices at the top of each source file mentions our and only our names, and as long as the same copyright notice is copied to any new source files you would create, and as long as you haven't made any changes to the contrary in the COPYING file. Other than that, it's mostly just a matter of technical details and getting in contact. It should be noted that, while there is a repository on GitHub for the client, it is mostly just for backup, and the GitHub account is not commonly used, so if you decide to send a GitHib Pull Request, do not be surprised if it goes unnoticed for an extended period of time. More certain ways of receiving a response include e-mail or private messages on the Haven & Hearth forums.
When relogging with a different account/character the automapper keeps the old instance and bugs out, requiring a client restart.
be able to save a file, share it and upload it, with all the objects or craft or buttons in the action bars.
so you can easily import them from one character to another, from one account to another, or for groups of friends.
would it be possible to differentiate the audio channels,
and thus be able to adjust the volume of the "tic-tic" notifications,
which are very VERY loud in game, and depend on the "master volume", i.e. to turn them down you have to turn them ALL down :/.
http://www.havenandhearth.com/forum/viewtopic.php?f=39&t=69278
Just in case your still interested in ...
it's maybe my FR translation need some fix
do I need to convert all accesses to UTF8 like
"%C3%A9" or "é" é for "é"
or does the problem come from somewhere else?
haven.RichText$FormatException: Junk left after the end of input:
at haven.RichText$Parser.parse(RichText.java:561)
at haven.RichText$Parser.parse(RichText.java:573)
at haven.RichText$Parser.parse(RichText.java:583)
at haven.RichText$Foundry.render(RichText.java:737)
at haven.RichTextBox.settext(RichTextBox.java:61)
at haven.CharWnd$LoadingTextBox.draw(CharWnd.java:741)
at haven.Widget.draw(Widget.java:776)
at haven.Widget.draw(Widget.java:781)
at haven.Widget.draw(Widget.java:776)
at haven.Widget.draw(Widget.java:781)
at haven.Widget.draw(Widget.java:776)
at haven.Widget.draw(Widget.java:781)
at haven.GameUI.draw(GameUI.java:1264)
at haven.Widget.draw(Widget.java:776)
at haven.Widget.draw(Widget.java:781)
at haven.RootWidget.draw(RootWidget.java:123)
at haven.UI.draw(UI.java:248)
at haven.GLPanel$Loop.display(GLPanel.java:312)
at haven.GLPanel$Loop.run(GLPanel.java:401)
at haven.JOGLPanel.run(JOGLPanel.java:246)
at java.base/java.lang.Thread.run(Thread.java:1583)
Got this crash only once for now, so no big deal, but still possibility there.
Occurred in fight with moose while he was fleeing and I spammed attack-peace to make him return to me.
java.lang.NegativeArraySizeException
at java.util.AbstractCollection.toArray(Unknown Source)
at java.util.ArrayList.(Unknown Source)
at haven.GobDamageInfo.clearAllDamage(GobDamageInfo.java:99)
at haven.Action.run(Action.java:93)
at haven.Fightsess.destroy(Fightsess.java:188)
at haven.Widget.reqdestroy(Widget.java:554)
at haven.UI.destroy(UI.java:346)
at haven.UI.destroy(UI.java:353)
at haven.RemoteUI.run(RemoteUI.java:72)
at haven.MainFrame.uiloop(MainFrame.java:301)
at haven.MainFrame.run(MainFrame.java:317)
at haven.MainFrame.main2(MainFrame.java:412)
at haven.MainFrame.lambda$main$0(MainFrame.java:448)
at java.lang.Thread.run(Unknown Source)
Related/(followup) to this forum post.
For when there might be a need to be able to test/reproduce this error.
So far the best chance (raw estimate: 75%+) in reproducing this error (on Linux-Mint at least) I found to be:
That it.
(A potential alternative (3 clients) would be to let a fully dressed+equipped character walk in on two naked characters. ... ie: the more resources two clients are given to load at the same moment, the higher the change that "Resource deadlock avoided" case is triggered.)
form other fork project (i don't know why he use properties files and not json)
i rename it json for github security
could you add it to your repo ?
updater-hafen.jar
to some folder, e.g. $HOME/Downloads/hafen
.updater-hafen.jar
.$HOME/Downloads/hafen
This is quite annoying, as it pollutes homedir with lots of game jar's and configuration files.
On Lubuntu 22.04x64
i have sometime this message when i start the launcher
OS: Ubuntu 22.04.3 LTS x86_64
Host: GL552VW 1.0
Kernel: 5.15.0-88-generic
Resolution: 1920x1080, 1050x1680
DE: LXDE
WM: Openbox
CPU: Intel i7-6700HQ (8) @ 3.500GHz
GPU: Intel HD Graphics 530
GPU: NVIDIA GeForce GTX 960M
Memory: 16Gio
java.lang.ArrayIndexOutOfBoundsException: Index 8239 out of bounds for length 256
at haven.FastText.textw(FastText.java:71)
at haven.FastText.aprint(FastText.java:78)
at haven.FastText.aprintf(FastText.java:110)
at haven.LoginScreen$StatusLabel.draw(LoginScreen.java:289)
at haven.Widget.draw(Widget.java:776)
at haven.Widget.draw(Widget.java:781)
at haven.LoginScreen.draw(LoginScreen.java:397)
at haven.Widget.draw(Widget.java:776)
at haven.Widget.draw(Widget.java:781)
at haven.RootWidget.draw(RootWidget.java:123)
at haven.UI.draw(UI.java:248)
at haven.GLPanel$Loop.display(GLPanel.java:312)
at haven.GLPanel$Loop.run(GLPanel.java:401)
at haven.JOGLPanel.run(JOGLPanel.java:246)
at java.base/java.lang.Thread.run(Thread.java:1583)
Hello, thank you for your wonderful work,
se-rais possible de placer votre autre depot en "archived".
if need, i can try help
When "Make flat terrain" is enabled, landscaping always shows that there is no soil needed, where in fact it is needed
need a fix for check if a waterbuket it's near and use it on priority
and don't take willstring
Shift-RMB allows you to view an area you're about to enter before entering it, and you can then LMB to enter the area. Doing so with 'warn about players' enabled warns you that it found a player and draws a red circle around your own character. (I can reproduce this with a house, haven't checked other entrances but presumably it's the same there.)
show radius of beehives/supports etc.
on github, go on release, "new release" , add tag, clic on generate auto-changlog
and valide,
that make you a release and a cool tag on you git history
Do you think it's possible to draw the CTRL + G grid with some transparency?
I like it on, but it's a bit intrusive.
hi !, first, thanks you read me, and thanks you for your work
could you, in futur update add a a cap or cover for a urn when it's full ?
could you add a field to craft x time
not "all" or "one"
Shift, Ctrl or Alt buttons can be used
I think that managing one's tree farm would be a somewhat less click-awkward exercise (when doing so with trees in hidden mode) if the tree hitbox would have its inner space filled (and being clickable of course).
It could be some solid color. Or, as per example, using some transparency (needs "A>128" if I recall it correctly).
strace:
java.lang.IllegalStateException: MappingClient should be initialized first!
at integrations.mapv4.MappingClient.getInstance(MappingClient.java:54)
at haven.GameUI.addchild(GameUI.java:948)
at haven.UI.newwidget(UI.java:246)
at haven.RemoteUI.run(RemoteUI.java:65)
at haven.MainFrame.uiloop(MainFrame.java:286)
at haven.MainFrame.run(MainFrame.java:302)
at haven.MainFrame.main2(MainFrame.java:448)
at haven.MainFrame.lambda$main$0(MainFrame.java:484)
at java.base/java.lang.Thread.run(Thread.java:834)
config.json:
{
"general": {
"storemap": true,
"start_toggle": {
"tracking": true
},
"toolbelt1": true,
"warning": {
"animal": {
"highlight": true,
"message": true
}
}
},
"ui": {
"menu_add_pick_all": true,
"progress_number": true,
"real_time_curio": true,
"show_curio_lph": true
},
"automap": {
"upload": true,
"track": false
},
"display": {
"gob_paths": {
"show": true,
"categories": [
"FOE",
"ME",
"AGGRESSIVE_ANIMAL"
]
},
"show_gob_radius": true
},
"version": "06.04.2021 20:14"
}
Noticed today that holding CTRL while placing stockpile or building for fine placement (not bound to grid) doesn't work anymore. Maybe a conflict with server where holding SHIFT in native client does the same thing (but without all the added benefits of Hafen with hitbox view, etc).
for exemple could you make a folder in ~/Games/HavenNHearth
or just "ask" where install the game
I don't know how other people are using this client right now, for me, after entirely resetting up the game from scratch, I get errors like these every time I load in, or shortly after.
java.lang.Error: Unexpected non-local exit
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:540)
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:531)
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:531)
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:531)
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:531)
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:531)
at haven.MapView$Gobs.removed(MapView.java:805)
at haven.OCache.remove(OCache.java:131)
at haven.OCache$GobInfo.apply(OCache.java:379)
at haven.Loader.lambda$defer$0(Loader.java:240)
at haven.Loader$Future.run(Loader.java:71)
at haven.Loader$Future.access$400(Loader.java:42)
at haven.Loader.loop(Loader.java:202)
at java.base/java.lang.Thread.run(Thread.java:1583)
Caused by: java.lang.IllegalStateException: removing non-present slot
at haven.render.InstanceList.remove(InstanceList.java:713)
at haven.render.RenderTree$Client.removed(RenderTree.java:110)
at haven.render.RenderTree$TreeSlot.lambda$remove$1(RenderTree.java:537)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)
at haven.render.RenderTree$TreeSlot.remove(RenderTree.java:537)
... 13 more
Hi,
I cloned the repo and compiled the project with ant, but can't log in the game. It says "Connection refused: connect".
Also, how do I debug? It says it cannot find the main method. I'm using Visual Studio Code. Should I use another IDE?
Not sure what's up here. Or how to get it back into some workable form.
Anyway ...
First I needed to updating the Vanilla client launcher. Previous one complained/crashed due to launcher being outdated ... Have not used in some time.
Because the Vanilla client was complaining about "Launcher login expired", I reset some saved account logins with it.
After that I did the same with the saved account login's in the Ender client.
But ... the Vanilla client is now not only complaining about "Launcher login expired". Its now it also refuses to login. Falling back to the account login screen with a "Invalid save" complained when I try it anyway. (it did not do that before I reset the account logins :( )
.../HnH/Ender$ md5sum launcher*
92910afeb530ef85e9d8d29940064881 launcher-hafen-beta.jar
1f4d8672077c9a65990d82e663bc8e26 launcher-hafen.jar
Caverats are somewhat rare underground creatures: http://ringofbrodgar.com/wiki/Caverat
They're pretty aggressive and hard to see due to their small size and their color. Would be nice if these could also be added to the dangerous creatures list.
(It's also absent from the Radar Settings list, being displayed as '???'. Charred trees and blood splatters are also '???' in that list.)
The resource name, according to X -> I, is 'gfx/kritter/rat/caverat'.
java.lang.AbstractMethodError
at haven.ItemInfo.buildinfo(ItemInfo.java:378)
at haven.GItem.info(GItem.java:189)
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
at java.util.stream.DistinctOps$1$2.accept(DistinctOps.java:175)
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
at haven.AttrBonusesWdg.doUpdate(AttrBonusesWdg.java:102)
at haven.AttrBonusesWdg.tick(AttrBonusesWdg.java:81)
at haven.Widget.tick(Widget.java:652)
at haven.Widget.tick(Widget.java:652)
at haven.Widget.tick(Widget.java:652)
at haven.GameUI.tick(GameUI.java:1006)
at haven.Widget.tick(Widget.java:652)
at haven.UI.tick(UI.java:140)
at haven.HavenPanel.run(HavenPanel.java:557)
at java.lang.Thread.run(Thread.java:748)
When you rotate camera holding a wheel, you need to change position of your index finger and you cannot press the left button at the same time. I also broke two mouses this way, because wheels are very vulnerable on cheap mouses.
Can you please add option to combine middle and right mouse buttons functionality together, to be able to open context menus and rotate camera at the same time on RMB?
haven.render.RenderTree$SlotRemoved: adding haven.ResDrawable@469ce05d
at haven.render.RenderTree$TreeSlot.add(RenderTree.java:475)
at haven.render.RenderTree$TreeSlot.add(RenderTree.java:408)
at haven.render.RenderTree$Slot.add(RenderTree.java:385)
at haven.RUtils.multiadd(RUtils.java:46)
at haven.Gob.lambda$updateVisibility$9(Gob.java:1273)
at haven.Loader.lambda$defer$0(Loader.java:240)
at haven.Loader$Future.run(Loader.java:71)
at haven.Loader$Future.access$400(Loader.java:42)
at haven.Loader.loop(Loader.java:202)
at java.base/java.lang.Thread.run(Thread.java:1583)
Hiding clam reef icon from Icon Settings don't hide them on minimap
Would it be possible to highlight gobs based on a filter for "has:x" "has:bough" "has:berries" for example. Would save some people who aren't 100% good at recognizing tree a lot of right clicking.
add ability to select current camera with ui, not just console command
I'm unsure of how it happened but my cattle roster window is missing. It may be off screen. Perhaps the window manager should prevent windows from leaving the viewable area? I'm also not sure if this issue should be more upstream.
After new update, developers implement new approach to work with items invetories. New chaneges requre to merge changes from vanilla client.
https://www.havenandhearth.com/forum/viewtopic.php?f=39&t=74247
https://www.havenandhearth.com/forum/viewtopic.php?f=39&t=74244
Merged top-down screenshots of a tile-centered heartling from two opposite positions (NS or EW).
Is it potentially fixable for a tile-centered heartling's position to be dead-center inside a tile (even in max zoomed-in view) ?
(mainly useful when such top-down (NSEW) screenshots are used for some personal projects.)
hp, stamina, hunfer, energy
actually if you put your curson on it, it show you number, i know some people like have this number always visible
As in the title: toon always walks toward center of clicked tile, regardless of setting.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.