Sphereserver / Source-X

Ultima Online server emulator
Apache License 2.0
58 stars 47 forks source link

CChar::CallGuards() function #1040

Closed canerksk closed 3 months ago

canerksk commented 1 year ago

Hello,

I guess because of a query under the CallGuards() function, it's not working as it should.

For example;

In the past, this command was working outside the guard zone, and when "guards" is written next to someone who is guilty, that person becomes a general criminal (criminal 1, Noto_Criminal() ). But right now, I saw that this function is stopped working except for city protection under the function.

    ADDTOCALLSTACK("CChar::CallGuards");
    if (!m_pArea || 
    !m_pArea->IsGuarded() || <-- its use other than gz is turned off here.
    IsStatFlag(STATF_DEAD|STATF_STONE))
        return;

In the current situation when I type the "guards" command outside of gz, someone who criminal me does not become a general criminal.

Do you think this is a bug?

drk84 commented 1 year ago

If the are is not guarded no guards should be called

canerksk commented 1 year ago

No just calling guards under the CChar::CallGuards() function,

if (m_pPlayer && Memory_FindObjTypes(pCriminal, MEMORY_SAWCRIME))
  pCriminal->Noto_Criminal(this, true);

query is also available. which should make that person "criminal 1" outside of city guard.

For those who still want the old style, keep this "Issue". If there are those who want the old style, they can express their opinions under this "Issue".