Hello!
I'm rather new to the coding scene...so please forgive me if this comes across as a stupid question...
I'm running a slightly modified SWR11FUSS...i say slightly, but its converted now over to C++ instead of C...at any rate...my question is this:
With mobprogs, roomprogs, objprogs and notes/disks...when you do something such as this:
mpedit whatever add speech test
(open buffer)
'This is the beginning of the mobprog tutorial course. Once you feel that you have mastered the training, please feel free to move on to the advanced mobprog tutorial area and see what you can see.
(close buffer)
Once you fire the program by saying 'test' you'll get this:
Whatever says, 'This is the beginning of the mobprog'
Once you go into the program do a /l, you'll see this:
1>'This is the beginning of the mobprog tutorial course. 2>Once you feel that you have mastered the training, please 3>feel free to move on to the advanced mobprog tutorial 4>area and see what you can see.
what I *want* is for this:
1>'This is the beginning of the mobprog tutorial course. Once you feel that you have mastered the training, please feel free to move on to the advanced mobprog tutorial area and see what you can see.
2>
So that way when you fire the trigger, you get the entire message instead of having to try to count out the 74 characters to a line. It just seems like it'd be much, much easier for the builders and would give a little bit more freedom with maneuvering. How would you cause notes and the different programs to read beyond the newline character?
Now, I've messed around in comm.cpp and tweaked with the line-length and such, changed it from 256 to 1024 so that the players can pretty much emote or say or whatever away without having to see the "Line too long" message. Anyhow, in doing this, I came across the function at around line 980 that looks like this:
for( i = 0; d->inbuf[i] != '\n' && d->inbuf[i] != '\r' && i < MAX_INBUF_SIZE; i++ )
{
if( d->inbuf[i] == '\0' )
return;
}
/*
* Canonical input processing.
*/
for( i = 0, k = 0; d->inbuf[i] != '~' && d->inbuf[i] != '\r'; i++ )
{
if( k >= 1024 )
{
write_to_descriptor( d, "Line too long.\n\r", 0 );
/*
* skip the rest of the line
*/
/*
* for ( ; d->inbuf[i] != '\0' || i>= MAX_INBUF_SIZE ; i++ )
* {
* if ( d->inbuf[i] == '\n' || d->inbuf[i] == '\r' )
* break;
* }
*/
d->inbuf[i] = '\n';
d->inbuf[i + 1] = '\0';
break;
}
Now...being inquisitive, I started asking around and learned that one would have to change the newline character to a tilde character, then install the smash-tilde function if it were not already installed. As can be seen, I changed the newline to a tilde...this is where I'm rather stumped. I know that what I'm doing *can* be done. When I've tweaked with it a little farther, I got it to almost working like I wanted to...leastways it didn't chop off at the end of line one. Unfortunately, it looked ugly since it was just reading line after line after line and then it started giving "Missing endif" errors on all mobs with progs...which is annoying since the endif was definately there.
Any assistance...preferably what I should change and how...would be highly appreciated...but just a tip to give a nudge in the proper direction would be completely spiffy.
Lots and many thanks!
Kerrias
aka
Jessica
I'm rather new to the coding scene...so please forgive me if this comes across as a stupid question...
I'm running a slightly modified SWR11FUSS...i say slightly, but its converted now over to C++ instead of C...at any rate...my question is this:
With mobprogs, roomprogs, objprogs and notes/disks...when you do something such as this:
mpedit whatever add speech test
(open buffer)
'This is the beginning of the mobprog tutorial course. Once you feel that you have mastered the training, please feel free to move on to the advanced mobprog tutorial area and see what you can see.
(close buffer)
Once you fire the program by saying 'test' you'll get this:
Whatever says, 'This is the beginning of the mobprog'
Once you go into the program do a /l, you'll see this:
1>'This is the beginning of the mobprog tutorial course. 2>Once you feel that you have mastered the training, please 3>feel free to move on to the advanced mobprog tutorial 4>area and see what you can see.
what I *want* is for this:
1>'This is the beginning of the mobprog tutorial course. Once you feel that you have mastered the training, please feel free to move on to the advanced mobprog tutorial area and see what you can see.
2>
So that way when you fire the trigger, you get the entire message instead of having to try to count out the 74 characters to a line. It just seems like it'd be much, much easier for the builders and would give a little bit more freedom with maneuvering. How would you cause notes and the different programs to read beyond the newline character?
Now, I've messed around in comm.cpp and tweaked with the line-length and such, changed it from 256 to 1024 so that the players can pretty much emote or say or whatever away without having to see the "Line too long" message. Anyhow, in doing this, I came across the function at around line 980 that looks like this:
for( i = 0; d->inbuf[i] != '\n' && d->inbuf[i] != '\r' && i < MAX_INBUF_SIZE; i++ )
{
if( d->inbuf[i] == '\0' )
return;
}
/*
* Canonical input processing.
*/
for( i = 0, k = 0; d->inbuf[i] != '~' && d->inbuf[i] != '\r'; i++ )
{
if( k >= 1024 )
{
write_to_descriptor( d, "Line too long.\n\r", 0 );
/*
* skip the rest of the line
*/
/*
* for ( ; d->inbuf[i] != '\0' || i>= MAX_INBUF_SIZE ; i++ )
* {
* if ( d->inbuf[i] == '\n' || d->inbuf[i] == '\r' )
* break;
* }
*/
d->inbuf[i] = '\n';
d->inbuf[i + 1] = '\0';
break;
}
Now...being inquisitive, I started asking around and learned that one would have to change the newline character to a tilde character, then install the smash-tilde function if it were not already installed. As can be seen, I changed the newline to a tilde...this is where I'm rather stumped. I know that what I'm doing *can* be done. When I've tweaked with it a little farther, I got it to almost working like I wanted to...leastways it didn't chop off at the end of line one. Unfortunately, it looked ugly since it was just reading line after line after line and then it started giving "Missing endif" errors on all mobs with progs...which is annoying since the endif was definately there.
Any assistance...preferably what I should change and how...would be highly appreciated...but just a tip to give a nudge in the proper direction would be completely spiffy.
Lots and many thanks!
Kerrias
aka
Jessica