How to change the name of Happyhour?

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
5 years 6 months ago #7650 by Nero
Hi,

I am a beginner coder for Circle Muds. We have a MUD that is already up and running but we want to be able to start implementing and integrating some more stuff to the MUD just to get some new ideas, zones, etc going.

One thing I want to do is add the happyhour feature however, I want to change the syntax from happyhour to bonus. So if someone types bonus, it does the same thing if someone typed happyhour. How would I go about changing that in the code?

Please Log in or Create an account to join the conversation.

More
5 years 6 months ago #7660 by rudeboyrave
Replied by rudeboyrave on topic How to change the name of Happyhour?
the quickest way to do this would be to edit the message shown on the who screen to show the word bonus instead of happy hour when one is going on... in act.informative.c change

if (IS_HAPPYHOUR > 0){
send_to_char(ch, "It's a Happy Hour! Type \tRhappyhour\tW to see the current bonuses.\r\n");
to
if (IS_HAPPYHOUR > 0){
send_to_char(ch, "It's a BONUS!! Type \tRbonus\tW to see the current bonuses.\r\n");


you could also edit interpreter.c and change
{ "happyhour", "ha" , POS_DEAD , do_happyhour, 0, 0 },
to
{ "bonus", "bo" , POS_DEAD , do_happyhour, 0, 0 },

and in act.other.c find do_happyhour and change all the send_to_char 's to say bonus instead of happyhour.


this is the easiest way to do this i think. it changes the look of everything without making all the changes to rename everything bonus from happy.

CyberASSAULT
www.cyberassault.org
cyberassault.org 11111
A post-apocalyptic, sci-fi MUD.

Please Log in or Create an account to join the conversation.

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
5 years 6 months ago #7688 by Nero
Replied by Nero on topic How to change the name of Happyhour?
Thanks for your response. For some reason I am having trouble integrating this into my circle mud files. I have everything in the right place but when typing 'happyhour' in the cmd prompt, nothing happens it gives me no dialogue at all just says, huh!?!.

The only difference between tbamud's files and mine is that I do not have an act.h - so I placed most of the code in the act.informative.c. I also do not have a DG_VARIABLES and instead use DG_SCRIPTS but it's essentially the same file.

What am I missing here?

Please Log in or Create an account to join the conversation.

More
5 years 6 months ago #7689 by rudeboyrave
Replied by rudeboyrave on topic How to change the name of Happyhour?
the reason the happyhour command isnt working is that we changed the command to bonus.
here:
you could also edit interpreter.c and change
{ "happyhour", "ha" , POS_DEAD , do_happyhour, 0, 0 },
to
{ "bonus", "bo" , POS_DEAD , do_happyhour, 0, 0 },


if you want the happyhour command to work as well as the bonus command then you would need to add
{ "happyhour", "ha" , POS_DEAD , do_happyhour, 0, 0 },
in interpreter.c

CyberASSAULT
www.cyberassault.org
cyberassault.org 11111
A post-apocalyptic, sci-fi MUD.

Please Log in or Create an account to join the conversation.

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
5 years 6 months ago #7705 by Nero
Replied by Nero on topic How to change the name of Happyhour?
It's currently set to happyhour as of right now to keep it simple for the integration

I do have { "happyhour", "ha" , POS_DEAD , do_happyhour, 0, 0 }, in my interpreter.c

The only thing is I do not have an act.h file where the ACMD(do_happyhour); resides so I am not sure where the best alternative place is for me to put that.

Please Log in or Create an account to join the conversation.

More
5 years 6 months ago #7708 by thomas
Replied by thomas on topic How to change the name of Happyhour?
act.wizard.h/.c ?

Please Log in or Create an account to join the conversation.

  • Nero
  • Nero's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
5 years 6 months ago #7713 by Nero
Replied by Nero on topic How to change the name of Happyhour?
Hi thanks for the reply. I was able to get this mostly working now by just re-arranging and working out the bugs.

Please Log in or Create an account to join the conversation.

Time to create page: 0.117 seconds