New lines are created by adding "\r\n" to the end of strings sent to send_to_char() function (act() already includes newlines).
So I believe the specific "\r\n" that you need to remove is this one, in act.social.c:44 :
Code:
if (!argument || !*argument) {
send_to_char(ch, "%s\r\n", action->char_no_arg); /* <---- remove the '/r/n' after %s */
act(action->others_no_arg, action->hide, ch, 0, 0, TO_ROOM);
return;
}
Can you check if that works for you?
On a side note, removing that will also remove newlines from emotes which do not need a target (ie. dance).
You could check for that using the fact that all socials that do not require a target also have "action->others_no_arg" set and not null. So the check would be something like this:
Code:
if (!argument || !*argument) {
send_to_char(ch, "%s%s",
action->char_no_arg,
action->others_no_arg ? "\r\n" : ""); /* <--- this will check if there is a message to be sent to others and add a newline only if something was sent to the room */
act(action->others_no_arg, action->hide, ch, 0, 0, TO_ROOM);
return;
}
But not sure if that would be enough for you since most of socials.new have "others_no_arg" set.