Aller au contenu

Photo

hak vs override


  • Veuillez vous connecter pour répondre
19 réponses à ce sujet

#1
Baaleos

Baaleos
  • Members
  • 1 329 messages
Question: If contents of a Hak pack, were extracted to override folder, would this allow access to the content just as easilly as it would if it were packed in a hak. Granted, I understand that overrides would be a global effect affecting potentially other modules, beyond the one intended, but I was just wondering if it was infact possible.




Eg - Some nice tilesets are out there, which are not actually that large in filesize, Im trying to avoid using hak's as much as possible, for the sake of player convenience etc.


The players of my module use an application I made, for updating their local content, which could be easilly set to distribute the contents of a hak pack I suppose.


So, original question.
Would a hakpack's content still be effective if placed in an override directory?


Note - If I do plan on proceeding with this plan, I would likely modify my application to backup the players override directory first, and give them the option to remove the downloaded content whenever desired.

#2
Calvinthesneak

Calvinthesneak
  • Members
  • 656 messages
It really depends on what the content is and what you're looking to modify. You have to be careful with 2da's. And you have to watch out because content in haks will actually override the content in overrides.

#3
Tarot Redhand

Tarot Redhand
  • Members
  • 2 674 messages
As far as I know stuff in the override directory will only override original Bioware content. So make sure that you are not trying original community made stuff in your override. For example you can't override Lord of Worms Seasonal Forest tileset but you can override the standard Rural one.



Also you don't need to write your own override manager, just check on the vault there are at least 2 nwn launcher programs that do just that.



TR

#4
Shadooow

Shadooow
  • Members
  • 4 468 messages
Hey,



As was said, override has lower priority than haks, so you cant add there some 2da that is already in haks you are using (CEP2). Also I would not mess with override much, many players have the override folder quite big and this could bring them big troubles if they would like to change anything.



You can use patch-hak or you can add new resources into cep2 haks, just be carefull on what you can add there and what you can not. For example you should not add tilesets there, because if client does not have he will crash... But placeables are fine, client which dont have it just wont see them etc. etc.

#5
Baaleos

Baaleos
  • Members
  • 1 329 messages
@ tarot - Im a c# Developer, so I kinda like to re-invent the wheel. Im quite pleased with my downloader application, it also has some features that the community ones likely do not have.
Eg - If you want custom sounds and voices in your module, for conversations etc. These MUST be wav format, otherwise they are not playable. But wav format is massive in filesize. I did my own tests, and 26 seconds of PCM Wav was 2mb in size, while the mp3 version of the same audio, was 128kb.

So, I made my Downloader, have a built in mp3->wav converter, which converts the mp3's it downloads, into wav on the clients machine.

This inturn, reduces the filesize of the file when being downloaded, but the client still gets the end result file.

@ShaDoOoW - Im specifically using my downloader, to distribute content that is being updated quite regularly, and hopfully without the need for haks.
While I suppose I could actually change the downloader to download a hak to the client machine instead, but then I run the risk of affecting their CEP23 stuff, if that is the hak I am using.

I feel much safer using the downloader to download to a clients override folder, because I have distributed my Downloader with a 'Delete Nosgoth Content' button, which downloads the filelist again, and this time, deletes all the files that it had downloaded in the first place.

The only file that would be deleted in this case that the player may not have wanted to lose, is the ambientmusic.2da, but the player is warned about this before they click on the confirm button etc.

All in all, I've tried to keep the downloader program as clean as possible, even programming it to be capable of recognizing files no longer required and deleting them.
Eg - a File that in the xml, has the tag TRUE. If it finds this file in the override, it will delete it, if its not present, then it just wont download it, since its been marked as delete, it is assumed it is an obsolete file.
Then it provides a report at the very end, showing all files successfully deleted,unsuccessfully deleted,downloaded, and fine.

Modifié par Baaleos, 26 juillet 2010 - 12:07 .


#6
Shadooow

Shadooow
  • Members
  • 4 468 messages

@ShaDoOoW - Im specifically using my downloader, to distribute content
that is being updated quite regularly, and hopfully without the need for
haks.

While I suppose I could actually change the downloader to
download a hak to the client machine instead, but then I run the risk of
affecting their CEP23 stuff, if that is the hak I am using.

Well cep2 has special hak for server-only stuff called cep2custom, its not intended for what you are trying to achieve, but it wont affect any possible cep updaters or what (i heard current cep has one) neither with clients, because clients have it empty.

also you dont have to dowload whole hak, for example tani's WorldGate is able to make/update hak, so you downloading only files in hak that were changed...

#7
Baaleos

Baaleos
  • Members
  • 1 329 messages
I do think it would be beneficial for me to learn how the update hak works.

I know cep team uses this, and it would be neater than the override directory.



However, as for the cep2_custom hak, I was orriginally using it for storing my ambientmusic.2da file, but then discovered there was issues if I had my 2da in a hak on server, and then clients had it in their override. Eg - They couldnt hear the custom music for some reason, even though they had the music bmu in their music folders.



In the end, I decided the ambientmusic.2da being in the override wasnt such a bad thing, and since then, in the hopes of avoiding hak content, which would involve players having to have the hak etc, I could just put my wav files in the override as well, since I am providing an easy method of removing them anyway.

#8
Estelindis

Estelindis
  • Members
  • 3 699 messages

Tarot Redhand wrote...
As far as I know stuff in the override directory will only override original Bioware content. So make sure that you are not trying original community made stuff in your override. For example you can't override Lord of Worms Seasonal Forest tileset but you can override the standard Rural one.

Not so.  At the CTP, we have often tested our tilesets in /override and they've worked just fine.  The override won't, um, override the hak version - but if you haven't associated the hak version with your module (which, I gather, the OP isn't doing), that doesn't come into play.  :)

#9
Lightfoot8

Lightfoot8
  • Members
  • 2 535 messages
The same question was asked not to long ago in the old fourms in the scripting section.

If you wanted to look at that post it is >> Override folder usage effects?



the first half stays on topic. the second page is more on the subject of proper use of the CEP custom hak.



the most usefull post in the thread is from Axe Murderer. wich is a link to his Custom Content Mechanics - A Tutorial by Axe on the vault



Axe Murderer Posted: Tuesday, 25 May 2010 07:53PM





See if this helps explain it a bit for you.



#10
_six

_six
  • Members
  • 919 messages
The most important and useful feature of a hakpak is that players without them can't log in to a server/module that requires 'em. That might not sound very useful, but if you are adding content rather than simply making visual modifications, this will cause all kinds of issues and potential crashes if the player's override does not contain everything the server's does. The only exceptions to this rule are some of the 2da files that are handled entirely server side, which includes a lot of rules-related ones that I can't quite recall off the top of my head.

Case in point: if you add a new tileset to a module via override, this will completely crash the game for players as soon as the module loading screen is complete if they do not have the tileset's .set file in their override.

As for any technical limitations regarding the override, well, any file that can go in a hakpak can also work in override - the only difference is that override textures must be .tga (incidentally the uncompressed, larger, slower loading format) to overwrite ingame resources, while .dds is required to override existing content in hakpaks. Oh, and .plt files that override existing ones do not work in override.

Ultimately the choice is between risking stability for a few graphical changes in override, and potentially completely transforming the look of the game without risk with the use of hakpaks. Though I can hardly be called unbiased in that analysis :bandit:

Modifié par _six, 26 juillet 2010 - 08:27 .


#11
Tarot Redhand

Tarot Redhand
  • Members
  • 2 674 messages
@Estelindis mmmf, mmmf, pop. Having removed my foot from my mouth thanks for the correction.



@Baaleos I think I understand what you are trying to do now. If you do decide to go down that path I would suggest that you give your players the option of which override folder to use as many of them will already have set up a number of such folders in order to play on a number of servers that have cc that players place in an override folder (custom heads, gui modifications etc).



TR

#12
Estelindis

Estelindis
  • Members
  • 3 699 messages

Tarot Redhand wrote...
@Estelindis mmmf, mmmf, pop. Having removed my foot from my mouth thanks for the correction.

No need for foot in mouth!  I just pointed out that it's possible - but, as Six mentions, it isn't necessarily desirable.  There's a reason we just use this method for testing and don't post an override version of the CTP.

That said...  Six, is there any reason the game should crash on module load (in the situation you describe) if the starter area is a standard tileset, rather than a (missing) custom one?

#13
Calvinthesneak

Calvinthesneak
  • Members
  • 656 messages
Just as a note, the other option to Worldgate for haks, is to use the Rsync system that Brian Chung was using when the 1.69 patch was in beta testing. I don't know anything about setting that up, but once players have the initial haks it will examine a manifest to check the contents of the haks and only update needed files inside of the haks.



For the nitty gritty technical details, I'm not sure who'd you ask on that. Something I've wanted to toy with forever and never gotten around to.

#14
_six

_six
  • Members
  • 919 messages

Estelindis wrote...

That said...  Six, is there any reason the game should crash on module load (in the situation you describe) if the starter area is a standard tileset, rather than a (missing) custom one?

IIRC it will crash if the number of tiles, features or groups in the server's copy of the .set is different to that of the clients. Additionally if the .mdl and .wok files are not present for the first tile the player touches on entering the area, this is liable to crash too.

Walkmesh data in either a model or wok should also never be altered by an override (except possibly to change material number, but I can't guarantee this is safe). As far as tilesets go, doing anything other than reskinning and adding aesthetic features to existing tiles will either crash the game or create lots of pathing and walkmesh glitches in multiplayer, if done from override.

Modifié par _six, 26 juillet 2010 - 03:42 .


#15
Frith5

Frith5
  • Members
  • 380 messages
The override has its uses, including modifying content in existing modules without having to rebuild that module using hak resources. Of course, if the contents of the .hak match the standard naming, etc., then that .hak will 'over ride' just as effectively any content already placed, once the hak is associated and the module built.

My question on this would be why? Why would you prefer your players to download override files instead of a .hak file? Either way requires players to download and install files in order to play, right? I can definitely see the attraction for SP games which are already built and which can use the override to automagically 'update' the look of that module. But for MP play, doesn't a .hak make more sense?

Of course, I could be wrong. Just asking. I use NWNCQ override for the OCs and other old modules, and I love it. For newer, or heavily modified with  CC modules already (like the fantasically awesome Arbor Falls!), I simply rename my override folders again to not use it. LoW already took great pains to craft his module a certain way, and I love seeing it the way he created it. Not so, some old SP module from the Vault, which is greatly improved by Chico's work (and other great overrides like Worms' and _six's).

Regards,
JFK

#16
Estelindis

Estelindis
  • Members
  • 3 699 messages

Frith5 wrote...
My question on this would be why? Why would you prefer your players to download override files instead of a .hak file? Either way requires players to download and install files in order to play, right?

Personally, I'm all for haks.  They keep things nice and tidy.  But I imagine that the aversion towards them has something to do with wanting to attract more players to one's server.  (Of course, if this just leads to crashing, as per Six's explanation, it seems a tad counter-productive.)

#17
Genisys

Genisys
  • Members
  • 525 messages
It would be best to extract the content, make a back up copy of the original hak, edit the files, then import them back into the Hak you will now be using (edited version), and then save the hak, test your changes, and then fix any issues you find... (Good adivce here)

All overrides you use, override ALL player's overrides and YOUR server's game files, so your module would be what they end up using, because your hosting it, therefore all changes you make trump all changes they make, if they are using overrides of the same name..

Files in your override may override files in your hak (and this is not a desired result), therefore editing files in your hak would be better, because your hak overrides other player's hak files...

So why have them download overrides?

Haks on the other hand, if it's a custom one, will require your players to download it BEFORE they log on to your server, and many players flat detest Haks and downloading files, overrides on the other hand are a better solution to avoid haks all together, HOWEVER< you can edit the CEP Top V Hak files without requiring a download, provided you are not doing anything major here...

Modifié par Genisys, 27 juillet 2010 - 06:50 .


#18
Estelindis

Estelindis
  • Members
  • 3 699 messages

Genisys wrote...
So why have them download overrides?

Well, we do have to think of the Mac (and Linux?) players too, who don't have the toolset (if I recall correctly).  Unless there's some utility out there for associating modules with hakpaks (like the PRC's installer), they're kinda stuck.

#19
_six

_six
  • Members
  • 919 messages

Genisys wrote...

All overrides you use, override ALL player's overrides and YOUR server's game files, so your module would be what they end up using, because your hosting it, therefore all changes you make trump all changes they make, if they are using overrides of the same name..

Um. Not quite - the only files where the servers' override the client copy are some 2das (and not all of them - polymorphing would be the infamous example of an exploit, although I think that was fixed in a patch, as well as appearance), and I believe most blueprint files will use the server's module copy rather than the player override version. Anything relating to art or sound assets or the 2das that handle them is handled entirely client side.

#20
Baaleos

Baaleos
  • Members
  • 1 329 messages
Hi guys,

Should really reply to some of these messages.



Hak's would be best yes, to keep my content separate from other servers that the player may play on.

Eg - The AmbientMusic.2da I am distributing, would probably override other servers, if they too distribute a 2da in the override too.

But saying that, if they distribute it via hak, then there is no issue.



I would love to be able to set my updater application to examine file contents of hak's but I currently dont know the file structure or how to create a hak reader class in c#.



Is there source code anywhere for examples of a hak reader/writer?

If there was some examples I could translate into c#, I would set my content up, to transfer the content into the players CEP2.3 Patch haks, making it possible for them to get access to even more content.

That being said, visual effects, placeables or tilesets, would cause crashes if the client didnt have the optional downloaded content.





In terms of the content I am distributing, it is strictly

BMU, and mp3's (which are then converted on client side, to wav).



These file types are optional and non-blocking.

Players will not crash, and they will not be refused entry if they do not have them.

They just wont hear the audio, making the content I am distributing an optional enhancement.



@Genisys -So why have them download overrides?



Because the wav files can be put in there, to make the audio available, and the 2da needs to be there to tell their client what audio to play.

The server doesnt send a PlayCommand to the client saying

Play BMU File "BMU_Music.bmu"

instead it sends a message saying

Play BMU 122

Then the client reads row 122 of the clients ambientmusic.2da, and then determines the file name of the bmu, and plays it.



This is similar to why tlk files are used, it takes less bandwidth and overhead to send a number, rather than sending a string filename. Plus, the row number can identify additional properties to that entry, if it has additional headings.