SphereCommunity
Read-only T_BOOK - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: Script Help (/Forum-Script-Help)
+--- Thread: Read-only T_BOOK (/Thread-Read-only-T-BOOK)



Read-only T_BOOK - tleilax - 02-15-2018 06:23 AM

Hello,

how do I make the book read-only? Also, how do I make new line on the same page (something like <br>)?

Seems like it changed a lot since 55i. Thanks.

Code:
[ITEMDEF i_book_test]
DEFNAME=i_book_test
ID=i_book_sm
TYPE=T_BOOK
RESOURCES=1 i_book_sm
WEIGHT=5
VALUE=500

CATEGORY=Decoration - Virtues
SUBSECTION=Virtue Items
DESCRIPTION=Book of Truth

ON=@Create
AUTHOR test
BODY test text



RE: Read-only T_BOOK - darksun84 - 02-15-2018 07:12 AM

For read only set the more1 value of the book to 0800


RE: Read-only T_BOOK - tleilax - 02-15-2018 07:15 AM

That works, thanks.

What is the correct way to add pages? Since I added MORE1=0800, the "BODY test text" stopped working.


RE: Read-only T_BOOK - darksun84 - 02-15-2018 08:00 AM

Set more1 = 0800 after you have finished to write the text.

Every time you use BODY you add one page, for adding a new line in the same page you have to tab the text :\
for example

body = "hello test" // Page 1 (actually body.0) First line is Hello second line is test
body = "fine bye bye" //Page 2 (body.1) First line is fine bye second line is empty third line is bye (Because there are two tabs)

Well the forum strips the tabs Tongue
Here again:
Code:
body = "hello    test" //  Page 1 (actually body.0)  First line is Hello second line is test
body = "fine bye        bye" //Page 2 (body.1) First line is fine bye second line is empty third line is bye (Because there are two tabs)