Modcraft - The community dedicated to quality WoW modding!

Projects => Software Development => Topic started by: schlumpf on January 31, 2012, 03:47:33 pm

Title: Things individual people want to be doing on Noggit.
Post by: schlumpf on January 31, 2012, 03:47:33 pm
Please use this thread on synchronizing what you want to change in Noggit, which ideas are good etc.

Please implement the following construct to use settings somewhen soon. ("assigned" to Mjollna.)
Code: [Select]
class application
{
  // ...
public:
  QVariant setting (const QString& key) const
  {
    return _settings.get (key);
  }
 
  void setting (const QString& key, const QVariant& value)
  {
    emit setting_about_to_change (key, setting (key));
    _settings.set (key, value);
    emit setting_changed (key, value);
  }

signals:
  void setting_about_to_change (const QString& key, const QVariant& value);
  void setting_changed (const QString& key, const QVariant& value);
};

// examples on how to use:

class foo_bar : public QObject
{
  Q_OBJECT

public:
  foo_bar (QObject* parent)
  : QObject (parent)
  {
    connect ( app()
            , SIGNAL (setting_changed (const QString& key, const QVariant& value))
            , SLOT (setting_changed (const QString& key, const QVariant& value))
            );
  }
public slots:
  void setting_changed (const QString& key, const QVariant& value)
  {
    if (key == "paths/game")
    {
      LogDebug << "game path changed to: " << value.toString().toStdString() << std::endl;
    }
  }
};

class settings_dialog : public QWidget
{
  // ...
  settings_dialog( ...)
  {
    connect (antialiasing_box, SIGNAL (valueChanged (int)), SLOT (set_antialiasing (int)));
    connect (app(), SIGNAL (setting_changed (const QString&, const QVariant&)), SLOT (setting_changed (const QString&, const QVariant&)));
  }

  void set_antialiasing (int value)
  {
    app().setting ("antialiasing", value);
  }

  void setting_changed (const QString& key, const QVariant& value)
  {
    if (key == "antialiasing")
    {
      antialiasing_box.setValue (value.toInt());
    }
  }
};
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on January 31, 2012, 05:20:37 pm
Hi there :)

So here's what I have in mind :

- First priority imho is having a nice Qt UI. Right now there are lots of menus and such to re-do, so that the program can be used again.
For the settings window and having settings changes saved, etc., as Schlumpf said I'm doing it.

- Then, there are the bugs on the bugtracker ( bugtraker/index.php (http://modcraft.io/bugtraker/index.php" onclick="window.open(this.href);return false;) ). Among them, the ground doodads thing ( bugtraker/index.php?do=details&task_id=103 (http://modcraft.io/bugtraker/index.php?do=details&task_id=103" onclick="window.open(this.href);return false;) ) and the mcal problem ( bugtraker/index.php?do=details&task_id=50 (http://modcraft.io/bugtraker/index.php?do=details&task_id=50" onclick="window.open(this.href);return false;) ) seem, to me, the most important ones, but again, it's just my opinion on the subject.
There's also that rendering problem of the terrain when using very small raising brush which seems quite problematic ( viewtopic.php?f=66&t=1047&start=15 (http://modcraft.io/viewtopic.php?f=66&t=1047&start=15" onclick="window.open(this.href);return false;) ).

- Lots of things are almost implemented in the code, ctrl+f todo if you're out of ideas. There's also always things to make nicer/cleaner.

- Then for new things... As I said on the Adt Converter topic, having LK features fully implemented would be awesome : mccv, mh2o... And that would prepare for a possible 4.x handling.
Title: Re: Things individual people want to be doing on Noggit.
Post by: phucko1 on January 31, 2012, 05:26:53 pm
Well, a rotate by degrees would be nice :P Aswell as a copy rotation from first selected to second selected :P
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on January 31, 2012, 06:02:42 pm
I actually have a question...
If I create an irc chan for people who want to contribute to Noggit dev, would you (Steff, Glararan, other people ?) join ?

It's so much easier to have a common place to chat all together...

-----[edit]

Well, created it, so if some people want to join :
Quakenet, #Noggit
Should be permanent in a few hours.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on January 31, 2012, 08:21:38 pm
Firs thin is to get all the stuff running again. Then Gui :)
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on January 31, 2012, 08:23:09 pm
We have 4 3 years now a chan but no one ever went in :)
I don´t think it useful to separate all the people. We are less enough to just use one place to communicate.
Title: Re: Things individual people want to be doing on Noggit.
Post by: glararan on January 31, 2012, 08:43:25 pm
Guys guys....wait wait with support for 4.x

after we do this work complete....we can start 5.x :D MoP is near...
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on January 31, 2012, 08:45:51 pm
Quote
We have 4 3 years now a chan but no one ever went in

Does it still exist ?
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on February 03, 2012, 10:01:02 pm
Just a short message to say I'm not inactive :)

Settings dialog is not finished, but it's getting better :
- Creating the settings dialog window : done.
- Getting the existing settings : done.
- Changing settings : one is done, the others will follow.
- Telling the rest of the app settings have changed : one should be ok soon, others will follow.

I'll commit when I finish the last step (could take some time though...).
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 03, 2012, 10:39:08 pm
Nice to see it is going on :)
Please test your code before you commit.
Means, clear you project and recreate with cmake, compile from zero and test your functions.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on February 04, 2012, 07:26:58 pm
I think a Modelviewer would be great so u dont have to start 2 Applications like noggit and WoWModelViewer.
i already started with this....but to be honestly i never did anything with opengl
[spoiler:1tb5s0fl](http://d.localhostr.com/file/ZaAsNjY/screen.png)[/spoiler:1tb5s0fl]
thats everything i got so far.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 04, 2012, 11:46:45 pm
You just can use the model class. So you dont must start from 0
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on February 05, 2012, 02:06:12 am
Quote from: "Steff"
You just can use the model class. So you dont must start from 0
i actually did this but there were some issues with textures which i had to solve....
(http://d.localhostr.com/file/lRJRL24/screen.png)
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 05, 2012, 10:11:54 am
Cool. Its going on :)
If someone could spend some time in selection problems. You cant select a model in QT last time i have looked.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on February 05, 2012, 03:58:33 pm
Quote from: "Steff"
Cool. Its going on :)
If someone could spend some time in selection problems. You cant select a model in QT last time i have looked.
selections are working for me.
Linux x64
qt 4.8
compiled with gcc within qt-creator (cmake not tested)
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 05, 2012, 10:21:48 pm
Ok then i will try this again.
Thanks.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on February 19, 2012, 10:56:54 pm
So about settings (Qt version)...

- Retrieving current settings : ok.
- Displaying a nice window to change settings : ok.
- Changing settings and saving them : ok.
- Telling app settings have changed : ok.
- Output change in Debug log : ok.

Todo :
- When settings change, actually do something (else than emitting signals) and update program behavior according to the change.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 20, 2012, 12:29:14 am
If you have tested the source good just push your changes :)
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on February 20, 2012, 07:22:13 pm
Done :)
I checked things several times so everything should be ok... Hope I haven't made mistakes with the repository (first time I'm using this), but it seems alright.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 21, 2012, 12:21:59 pm
The commit works fine. Compiles and runs :)

But WMO Selection still don´t work. m2s are fine.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on February 21, 2012, 02:18:49 pm
wmo seems to be a bit tricky, but i will have a deeper look these days
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 21, 2012, 05:00:39 pm
I fight in the moment with the wmo save in SDL version. We must also have a look if that s also a problem in QT version.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on February 22, 2012, 10:39:41 pm
found a solution for wmo selection bug yesterday.....will have a look at wmo save
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on February 23, 2012, 06:09:00 am
If you find the problem just send me a hint. So i can activate again also in SDL version.
Thansk :)
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on February 26, 2012, 02:53:43 pm
Quote from: "Steff"
If you find the problem just send me a hint. So i can activate again also in SDL version.
Thansk :)
in qt version the  "checkinside" function seems to fuck up everything.....when i comment it out it works....
dunno if SDL has the same issue
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on May 26, 2012, 12:20:25 pm
Hi there !
 
I have a few questions about settings, so I thought I'd explain them here.

The idea



Two days ago a few friends asked me to compile for them the latest rev from the repo (qt-no-old-ui branch, rev 456 to be exact), since they wanted to test/see/play a little, even knowing that the UI is not finished.
That was also a good means to let me see if the path settings I had committed some months ago would work, and how users who don't know anything about the new system would react.
 

Problems encountered



Auto-detection of the Wow version installed almost always fails



The reasons are as many as there are potential users, which means a lot of hassle for everyone (imho).
 
Lots of people, especially those interested into modding, have multiple Wow installs, of different versions, sometimes with different locales. So there's no way to detect the right install at first try, it's just pure luck :
 

Locale problem



Friend 1 had Cataclysm detected automatically with enGB locale. I told him to manually enter in regedit (which really is bad means to do and should never happen >.<) the path to his 335a. After that Noggit seemed lost and couldn't find most of his files... until we found out he only had frFR locale on his 335a.
 

Changing folders



Imagine someone defines a proper Wow install. Everything works fine for a while.
Then the person moves his Wow install for whatever reason. There is one install defined so Noggit will try to load the files, but the install has disappeared, so there's a big chance it won't load at all, and thus the user can never reach the settings button to change the path.
On the contrary, it would probably not be really comfortable to have the settings popup at every launch.
 

Conclusion (my opinion on all this)



Definitely, when there's no install defined, i.e no previously defined config, the settings should pop at first launch before anything else (yes Schlumpf you're right, I remember you told me about this). That would also mean remove any auto-detection attempt.

It would probably be better to ask which locale people want to use in case they have several ones, and allow them to change it manually later... ?

I'd also like to add the fact that if install is not valid (files don't load/are not found for whatever reason, even though there are settings defined), the settings windows pops again.

Finally, I'd also like to reload the maps lists/tabs when paths are changed, to avoid problems (attempt to load files from an invalid/previous location). And if there's a map window loaded, maybe it's possible to disable paths changing until it's closed ? Idk.
 
What do you think ?
 
If you're ok I can change the settings behaviour to take this into account... no promise on delay though, some things are harder than others in what I've listed above. But I feel better now when looking at the code, so I think I'll be faster than 5 months :)
Title: Re: Things individual people want to be doing on Noggit.
Post by: glararan on May 27, 2012, 10:52:36 am
I have some ideas.

- Zoom in/out in choosing map (Like Sharpwow)
- Small icons on Toolbar now 40x40 (to 24x24?)
- Alt + right mouse action increase/decrease brush speed

EDIT:
- Load MPQ, ... on File -> Open Maps
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on May 27, 2012, 03:32:02 pm
For options. There should be first an soruce managerr where you can setup clint folders for different file versions. Like 335a 406 etc. Then if you load a file and noggit is able to laode it (depends on the progress Mjolna make :) ) noggit can use the fitting client to get stuff.

Also if you create later a proejct you setup the client version this project is for. Now noggit can use the fitting MPQ source. But it should also be possible so setup an onw source in the project. If you creat an addon for an existing release.
Title: Re: Things individual people want to be doing on Noggit.
Post by: glararan on May 27, 2012, 05:58:21 pm
Change game dir is some time implemented by Mjo.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Hanfer on May 27, 2012, 06:02:23 pm
beside that steff said the windows registry solution is not a good one...
in my opion we should replace it with a simple QFileDialog where user should select his wow.exe
this works on all plattforms, u can select the wow version u like and its nearly fail save....
Title: Re: Things individual people want to be doing on Noggit.
Post by: schlumpf on May 27, 2012, 08:21:49 pm
The auto detection is fine (except for being fucked up on windows again and again due to people not knowing about the virtual registry and adding wrong paths for loading. More than doing that is just impossible. It is fine, just let it be.

There is no reason to edit stuff in registry and telling people they would need to is just plain wrong. Storing stuff there is perfectly fine and will not be changed.

When you change stuff and Noggit will now no longer find stuff for your locale / whatever, that's an error on the "I'll just edit it in the registry" side not on Noggit.

Of course there is no handling for stuff changing right now. The small settings dialog is just opened on the wrong place.

Autodetection is fine, should stay in. Instead of crashing upon loading, it shall display the settings dialog (this is the case for never configured or moved folders). The locale of course also should be in the settings. Every setting should be changeable at any point.


The registry is fine. Just expand the settings dialog and use it instead of complaining.

Also, replace all QStrings with QFiles when handling directories to prevent  /  fuckups, like they exist right now.


Quote from: "glararan"
I have some ideas.

- Zoom in/out in choosing map (Like Sharpwow)
- Small icons on Toolbar now 40x40 (to 24x24?)
- Alt + right mouse action increase/decrease brush speed

EDIT:
- Load MPQ, ... on File -> Open Maps
Not sure if needed.
Will scale down anyways.
wasn't there already one?
Don't understand that one.
Title: Re: Things individual people want to be doing on Noggit.
Post by: glararan on May 27, 2012, 08:23:58 pm
Quote from: "schlumpf"
Quote from: "glararan"
I have some ideas.

- Zoom in/out in choosing map (Like Sharpwow)
- Small icons on Toolbar now 40x40 (to 24x24?)
- Alt + right mouse action increase/decrease brush speed

EDIT:
- Load MPQ, ... on File -> Open Maps
Not sure if needed.
Will scale down anyways.
wasn't there already one?
Don't understand that one.

- Load MPQ is thinked when you want work on Map editing you will start using now MPQs, until now you can edit them, ...
- I dont know if there was this feature. (alt + r mouse)
Title: Re: Things individual people want to be doing on Noggit.
Post by: Mjollna on May 27, 2012, 08:43:30 pm
Quote
The auto detection is fine (except for being fucked up on windows again and again due to people not knowing about the virtual registry and adding wrong paths for loading. More than doing that is just impossible. It is fine, just let it be.
Ok.

Quote
There is no reason to edit stuff in registry and telling people they would need to is just plain wrong. Storing stuff there is perfectly fine and will not be changed.
I agree storing in registry is ok.

Quote
Of course there is no handling for stuff changing right now. The small settings dialog is just opened on the wrong place.
I agree, that's why I said I wanted to change this.

Quote
Also, replace all QStrings with QFiles when handling directories to prevent /  fuckups, like they exist right now.
Ok I'll do that.
Title: Re: Things individual people want to be doing on Noggit.
Post by: Steff on May 27, 2012, 09:37:59 pm
The proglem is if you have more then one wow on your hd and open them also from time to time. I don´t want to start the noggit wow every time i want to use noggit. I just want to set this fix in a settings dialog and thats it.

If you start noggit the first time the settings dialog should pop up and give you the auto detected wow as an proposal. Set the right client version and it is added. If its the wrong client you can just use the folder selector to get the right one.