Jump to content

[C++]Disable chat on ox event?


Recommended Posts

You can check when the chat command is handled (I guess it's in one of the input cpps) for the map index and then return beforehand. So people can't chat when they're in OX. You can also make an exception when the chat type is whispering, so people can talk privately via pm but not use the normal, guild, group or all chat^^

Edited by Alina
  • Love 2
Link to comment
Share on other sites

If you're using source you can do this via input_main.cpp:

Before CBanwordManager::instance().ConvertString(buf, buflen); add this code:

	if(ch->GetMapIndex() == MAP_OX_ID && (pinfo->type == CHAT_TYPE_TALKING || pinfo->type == CHAT_TYPE_PARTY || pinfo->type == CHAT_TYPE_GUILD || pinfo->type == CHAT_TYPE_GUILD))
	{
		return iExtraLen;
	}

Otherwise if you're not using the source I guess I don't know any other way

Edited by Denis
  • Love 1
Link to comment
Share on other sites

If you're using source you can do it by this way via input_main.cpp:

Before CBanwordManager::instance().ConvertString(buf, buflen); add this code:

	if(ch->GetMapIndex() == MAP_OX_ID && (pinfo->type == CHAT_TYPE_TALKING || pinfo->type == CHAT_TYPE_PARTY || pinfo->type == CHAT_TYPE_GUILD || pinfo->type == CHAT_TYPE_GUILD))
	{
		return iExtraLen;
	}

Otherwise if you're not using the source I guess I don't know any other way

Add to all codes CBanwordManager :: Instance (). ConvertString (buf, buflen);? there are two

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



  • Similar Content

  • Activity

    1. 23
    2. 2

      Stripe payments

    3. 2

      Stripe payments

    4. 144

      Shop Ex Renewal

    5. 0

      Sort By Last Play Time problem

    6. 0

      QuickSell in SpecialInventory Problem

    7. 12

      Legendary items effect

    8. 0

      M2Project Research | Teamler - Beta Tester

  • Recently Browsing

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.