Does Mudlet have a way to align cecho/echo to the right or center, instead of to the left as it is now?
I made a way using string.rep(" ", number) but on some screens the number is too long or, too short. Or Will I have to make some script witht he .rep function?
cecho/echo Alignment
Re: cecho/echo Alignment
I seen thaat but too complicated for what I was after... and the output isnt what I was after either as I want it to be something like
[ OUTC: plantname (totalleeft) ]
[ OUTC: plantname (totalleeft) ]
Re: cecho/echo Alignment
Would something like this be too complicated?...
Re: cecho/echo Alignment
Am I missing something, The above does nothing... :/Akaya wrote:Would something like this be too complicated?...
I want something simple as people who hardly know how to code will be using it, And I want to be able to move it from left, right or center depending on what the person wants
Re: cecho/echo Alignment
If you use the script from the above link, it does exactly what you're describing in a single function.
First parameter is what you'd like to echo. Second parameter is a table of how you'd like it styled in any order. Centered and whatnot. Can't get much more simple than that
First parameter is what you'd like to echo. Second parameter is a table of how you'd like it styled in any order. Centered and whatnot. Can't get much more simple than that
Re: cecho/echo Alignment
I tried but its just aligning to the left.. not center as what you posted stated ... It why im confused
cecho(calign("[ OUTC: plantname ("..total_left..") ]",{"center",}))
echo(calign("[ OUTC: plantname ("..total_left..") ]",{"center",}))
Are what I tried to use
cecho(calign("[ OUTC: plantname ("..total_left..") ]",{"center",}))
echo(calign("[ OUTC: plantname ("..total_left..") ]",{"center",}))
Are what I tried to use
Last edited by icesteruk on Thu Jun 05, 2014 4:58 am, edited 1 time in total.
Re: cecho/echo Alignment
Ok, so are there any errors in the error console?
These should help us to figure out where it's breaking down.
These should help us to figure out where it's breaking down.
Re: cecho/echo Alignment
No errors, its showing just not, alignin correctly ...
[ OUTC: plantname (377) ] is whats being shown..
Unsure if this is a issue but it looks like its followng on from the prompt before (that shouldn't be happening I guess)
8%|S:100|xp 71.4%|(m/c) [ OUTC: plantname << prompt line
(1974) ] << new line
---
0.00%] [csdb eb] |B0|E:98%|S:100|xp 71.4%|(m/c)outc slice
You remove 1 testis slice, bringing the total in the cache to 40.
Is what im trying to make align to the right, the You remove line
[ OUTC: plantname (377) ] is whats being shown..
Unsure if this is a issue but it looks like its followng on from the prompt before (that shouldn't be happening I guess)
8%|S:100|xp 71.4%|(m/c) [ OUTC: plantname << prompt line
(1974) ] << new line
---
0.00%] [csdb eb] |B0|E:98%|S:100|xp 71.4%|(m/c)outc slice
You remove 1 testis slice, bringing the total in the cache to 40.
Is what im trying to make align to the right, the You remove line
Re: cecho/echo Alignment
or "center" etc.