Altering .cpp to make mechanically unsoloable bosses --> fully soloable - azerothcore

What would I need to change in the following .cpp files to make that encounter fully soloable?
boss_razorgore.cpp
(How could I prevent adds from spawning, or alternatively, reduce the number of eggs that initially spawn?)
boss_lord_marrowgar.cpp
(How could I prevent bone spike graveyard from ever being cast)
boss_valithria_dreamwalker.cpp
(How can I make it so the encounter ends successfully when Valithria is healed any amount instead of to 100%)
boss_icecrown_gunship_battle.cpp
(No idea here)
Mechanically unsoloable encounters; looking for simple changes in .cpp to make soloable.

Related

Explanation of "hardcoded" font on a piece of text, and how to remove it via CSS etc

I'm unable to understand how a piece of text has some kind of hardcoded font in it, that cannot be removed even after pasting into an RTE, application of CSS etc. See 2 examples below copied from various places:
Sample 1 - this font is apparently Cambria Math, and will not / cannot be overridden by CSS when displaying or removed when pasting into an RTE. Eg take this text and dump into CKEditor, QuillJS and any other, it will remain the same. In fact the same is happening right here in this editor - the font is not getting removed, and I'm unable to explain why.
๐ˆ๐ง๐๐ฎ๐ฌ๐ญ๐ซ๐ฒ ๐š๐ง๐š๐ฅ๐ฒ๐ฌ๐ข๐ฌ ๐ข๐ฌ ๐š ๐œ๐ซ๐ฎ๐œ๐ข๐š๐ฅ ๐ฌ๐ญ๐ž๐ฉ ๐ข๐ง ๐ญ๐ก๐ž ๐œ๐ฎ๐ซ๐ซ๐ž๐ง๐ญ ๐œ๐จ๐ฆ๐ฉ๐ž๐ญ๐ข๐ญ๐ข๐ฏ๐ž ๐ฆ๐š๐ซ๐ค๐ž๐ญ ๐ฌ๐ฉ๐š๐œ๐ž ๐ญ๐ก๐š๐ญ ๐ก๐ž๐ฅ๐ฉ๐ฌ ๐ข๐๐ž๐ง๐ญ๐ข๐Ÿ๐ฒ ๐ญ๐ก๐ž ๐ซ๐ข๐ ๐ก๐ญ ๐ญ๐š๐ซ๐ ๐ž๐ญ ๐œ๐ฎ๐ฌ๐ญ๐จ๐ฆ๐ž๐ซ๐ฌ ๐š๐ง๐ ๐š๐œ๐œ๐จ๐ซ๐๐ข๐ง๐ ๐ฅ๐ฒ ๐ฉ๐ซ๐จ๐ฏ๐ข๐๐ž ๐ญ๐š๐ข๐ฅ๐จ๐ซ๐ž๐ ๐ฌ๐จ๐ฅ๐ฎ๐ญ๐ข๐จ๐ง๐ฌ ๐Ÿ๐จ๐ซ ๐ญ๐ก๐ž๐ข๐ซ ๐›๐ฎ๐ฌ๐ข๐ง๐ž๐ฌ๐ฌ ๐ง๐ž๐ž๐๐ฌ. ๐„๐ฏ๐ž๐ซ๐ฒ ๐š๐ฌ๐ฉ๐ž๐œ๐ญ ๐š๐ง๐ ๐ฎ๐ง๐ข๐ช๐ฎ๐ž ๐œ๐ก๐š๐ฅ๐ฅ๐ž๐ง๐ ๐ž๐ฌ ๐ฉ๐ฎ๐ญ ๐ฎ๐ฉ ๐›๐ฒ ๐ญ๐ก๐ž ๐ฉ๐š๐ซ๐ญ๐ข๐œ๐ฎ๐ฅ๐š๐ซ ๐ข๐ง๐๐ฎ๐ฌ๐ญ๐ซ๐ฒ ๐š๐ซ๐ž ๐œ๐š๐ซ๐ž๐Ÿ๐ฎ๐ฅ๐ฅ๐ฒ ๐ญ๐š๐ค๐ž๐ง ๐ข๐ง๐ญ๐จ ๐œ๐จ๐ง๐ฌ๐ข๐๐ž๐ซ๐š๐ญ๐ข๐จ๐ง ๐ฐ๐ก๐ข๐ฅ๐ž ๐Ÿ๐จ๐ซ๐ฆ๐ฎ๐ฅ๐š๐ญ๐ข๐ง๐  ๐ญ๐ก๐ž๐ฌ๐ž ๐ฌ๐จ๐ฅ๐ฎ๐ญ๐ข๐จ๐ง๐ฌ. ๐ˆ๐ญ ๐š๐ฅ๐ฌ๐จ ๐ญ๐š๐ค๐ž๐ฌ ๐ข๐ง๐ญ๐จ ๐œ๐จ๐ง๐ฌ๐ข๐๐ž๐ซ๐š๐ญ๐ข๐จ๐ง ๐ฏ๐š๐ซ๐ข๐จ๐ฎ๐ฌ ๐ ๐จ๐ฏ๐ž๐ซ๐ง๐ฆ๐ž๐ง๐ญ ๐ซ๐ž๐Ÿ๐จ๐ซ๐ฆ๐ฌ, ๐œ๐จ๐ฆ๐ฉ๐ž๐ญ๐ข๐ญ๐ข๐ฏ๐ž ๐ž๐ง๐ฏ๐ข๐ซ๐จ๐ง๐ฆ๐ž๐ง๐ญ, ๐œ๐ฎ๐ฌ๐ญ๐จ๐ฆ๐ž๐ซ ๐›๐ž๐ก๐š๐ฏ๐ข๐จ๐ซ, ๐ž๐ฑ๐ข๐ฌ๐ญ๐ข๐ง๐  ๐š๐ง๐ ๐ฎ๐ฉ๐œ๐จ๐ฆ๐ข๐ง๐  ๐›๐ฎ๐ฌ๐ข๐ง๐ž๐ฌ๐ฌ ๐ฆ๐จ๐๐ž๐ฅ๐ฌ, ๐š๐ง๐ ๐ž๐ฏ๐ž๐ซ-๐ž๐ฏ๐จ๐ฅ๐ฏ๐ข๐ง๐  ๐ญ๐ž๐œ๐ก๐ง๐จ๐ฅ๐จ๐ ๐ข๐œ๐š๐ฅ ๐๐ž๐ฏ๐ž๐ฅ๐จ๐ฉ๐ฆ๐ž๐ง๐ญ๐ฌ. ๐ˆ๐ง๐๐ฎ๐ฌ๐ญ๐ซ๐ฒ ๐š๐ง๐š๐ฅ๐ฒ๐ฌ๐ข๐ฌ ๐ก๐ž๐ฅ๐ฉ๐ฌ ๐š๐ง ๐จ๐ซ๐ ๐š๐ง๐ข๐ณ๐š๐ญ๐ข๐จ๐ง ๐Ÿ๐จ๐ซ๐ฆ๐ฎ๐ฅ๐š๐ญ๐ž ๐ฌ๐ญ๐ซ๐š๐ญ๐ž๐ ๐ข๐ž๐ฌ ๐š๐ง๐ ๐ฉ๐จ๐ฅ๐ข๐œ๐ข๐ž๐ฌ ๐จ๐Ÿ ๐š ๐›๐ฎ๐ฌ๐ข๐ง๐ž๐ฌ๐ฌ.
Sample 2 - this is how it should be. When rendered the target CSS font is used.
Allowing PUT as create operations is problematic, as it necessarily exposes information about the existence or non-existence of objects. It's also not obvious that transparently allowing re-creating of previously deleted instances is necessarily a better default behavior than simply returning 404 responses.
More info if needed:
I saw this occur here https://www.althealth.me/topics/792/article/2888/rigid-knee-braces-market-is-expected-to-. This is an instance on the MainCross platform which is created by me.

How can I increase the line length in Atom with prettier-atom?

When my lines run a bit too long, saving the file auto-formats the code into multiple lines. I've spent more than I care to admit figuring out how to increase the line length to avoid multiple lines yet nothing seems to work. It seems like Atom doesn't want to pick up any of my config files. I have a ~./prettierrc file that's not recognized. And is printWidth the right option to use?
What's the easiest way to do this?
I had to restart Atom for the changes to take effect. https://github.com/prettier/prettier-atom/issues/489

Gulp โ€” how to get lazy, โ€˜makeโ€™-like building?

I am using gulp for css and js processing. Sometimes I am missing the good old lazyness of the unix make command:
only generate transformed (whatsover, e.g. compilation) files from original files, that have actually changed (based on time stamps).
this is true from stage 1 to 2 (.cpp -> .o), stage 2 to 3 (linking or other stuff) whatever your dependency graph gives...
Make is not limited to source code: You can do image manipulation in several steps (efficiently โ€˜lazyโ€™ generation of downscaled thumbs for example) or much else. All based on the fairly simple rule: โ€žis at least one of the source files newer in respect to the current output file(s)?โ€œ
Unlike gulp, every step generates (more or less temporary) files, not a continuous pipe.
Is there a way, to get the same kind of lazyness in gulp**, i.e. when generating css?
only transform those (less|sass|stylus) filesโžcss if something changed (on the very respective file)
same for adding in browser prefixes, concat, minify
Admittedly, beyond the first 1 or 2 steps, the output is most likely already a single stream. So any change means โ€˜touchedโ€™. Still, when playing for example with minify options, I'd rather be lazy about the early transpile, prefixing and concat stages (drawing prior results from a temp file). Also on the javascript side ( typeScript, ... )
lazypipe and gulp-cache sound tempting but are something else, if I understand correctly. Saying .watch() is also only a partial answer, for the very first stage.
Is there a more generic approach?
If you're set on using Gulp, then this would seem to be the way to do it. It involves the gulp-cached and gulp-remember plugins.

Reading multiple lines from QTextedit

I'm trying to write my own code-editor, I figure its a good way to learn pyQt.
I am using a qtextedit, in which i can write code(it's not real code, more pseudo code).
Each line represents ending in a semi-colon represents some command
e.g.
PSEUDO->FWD->90;
PSEUDO->STOP;
PSEUDO->RIGHT 90;
PSEUDO->FWD 10;
These are relatively easy to read, as the user presses the [ENTER] the current line is read, parsed and checked for errors so the following
PSEUDO->RIGHT -pi/2
would generate an error because the line doesn't end in a semi-colon and the value following RIGHT needs to be a number.(my editor, my rules).All this I have more or less got working.
I would like to know how to do multiple lines though. I am familiar with editors such as Eclipse,sublime or visual studio which handle muliple lines very well, in my case
PSEUDO->DO:
FWD->90
RIGHT->45
FWD->10
LEFT->55
FWD->50
STOP;
Should all be read in and treated as one statement, starting at the keyword PSEUDO and ending at the semi-colon.
However the following should be read as 3 separate statements.
PSEUDO->DO:
FWD->90
RIGHT->45
FWD->10
LEFT->55
FWD->50
STOP;
PSEUDO->DO:
FWD->90
RIGHT->45
STOP;
PSEUDO->BACK 10;
My question how can I go about reading muliple lines as described above from QTextEditor as discreet statements.
Should I do the parse/check whenever I press the [ENTER] key for a new line?
I'm using python2.7,pyQT, and QTextEdit.
Basically what you are trying to do, can be done with all the text of the document and some regular expressions. I would be careful with this course, because it may slow things down.
So to stay lean and to use the right classes of Qt, I would use anything related to the Rich Text Processing, QTextDocument, and QTextCursor.
I have used QSyntaxHighlighter quite a bit, and QRegExp. There is now QRegularExpression, too. Here are the classes and general documentation I'd look at to get started with Rich Text processing.
http://doc.qt.io/qt-5/qtextblock.html#details
http://doc.qt.io/qt-5/richtext-structure.html
http://doc.qt.io/qt-5/richtext.html
http://doc.qt.io/qt-5/richtext-cursor.html
http://doc.qt.io/qt-5/richtext-common-tasks.html#finding-text
Hope that helps.

How to insert text into middle of text file in QT?

I'm writing a program that performs several tests on a hardware unit, and logs both the results of each test and the steps taken to perform the test. The trick is that I want the program to log these results to a text file as they become available, so that if the program crashes the results that had been obtained are not lost, and the log can help debug the crash.
For example, assume a program consisting of two tests. If the program has finished the first test and is working on the second, the log file would look like:
Results:
Test 1 Result A: Passed
Test 1 Result B: 1.5 Volts
Log:
Setting up instruments.
Beginning test 1.
[Steps in test 1]
Finished test 1.
Beginning test 2.
[whatever test 2 steps have been completed]
Once the second test has finished, the log file would look like this:
Results:
Test 1 Result A: Passed
Test 1 Result B: 1.5 Volts
Test 2 Result A: Passed
Test 2 Result B: 2.0 Volts
Log:
Setting up instruments.
Beginning test 1.
[Steps in test 1]
Finished test 1.
Beginning test 2.
[Steps in test 2]
Finished test 2.
All tests complete.
How would I go about doing this? I've been looking at the help files for QFile and QTextStream, but I'm not seeing a way to insert text in the middle of existing text. I don't want to create separate files and merge them at the end because I'd end up with separate files in the event of a crash. I also don't want to write the file from scratch every time a change is made because it seems like there should be a faster, more elegant way of doing this.
QFile.readAll will read the entire file into a QByteArray.
On the QByteArray you can then use insert to insert text in the middle,
and then write it back to file again.
Or you could use the classic c style that can modify files in the middle with the help of filepointers.
As #Roku pointed out, there is no built in way to insert data in a file with a rewrite. However if you know the size of the region, i.e., if the text you want to write has a fixed length, then you can write an empty space in the file and replace it later. Check
this discussion in overwriting part of a file.
I ended up going with the "write the file from scratch" method that I mentioned being hesitant about in my question. The benefit of this technique is that it results in a single file, even in the event of a crash since the log and the results are never placed in different files to begin with. Additionally, rewriting the file only happens when adding new results (an infrequent occurrence), whereas updating the log means simply appending text to the file as usual. I'm still a bit surprised that there isn't a way to have the OS insert text into a file for you.
Oh, and for those of you who absolutely must have this functionality as efficiently as possible, the following might be of use:
http://www.codeproject.com/Articles/17716/Insert-Text-into-Existing-Files-in-C-Without-Temp
You just cannot add more stuff in the middle of a file. I would go with two separate files, another for the results and another for the logs.

Resources