TinTin++ Mud Client The TinTin++ message board

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
TinTin++ Mud Client

Github User's Group, Documentation & Shared Library

 
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> General Discussion
View previous topic :: View next topic  
Author Message
oxsyn



Joined: 05 Aug 2014
Posts: 1

PostPosted: Tue Aug 05, 2014 10:10 pm    Post subject: Github User's Group, Documentation & Shared Library Reply with quote

After another hiatus from mudding, I just started back up. Earlier today I created a TinTin group on github, with a couple shared projects I'm working on - the landing page for the group is here:

https://tintinplusplus.github.io/

I'm currently working on two projects - one is trying to document some common tintin 'recipes' (currently specific to the codebase I'm working on) and the second is a shared library - for which I've created some working solutions, but still need to fix them up a bit and publish them.

In any case, it's there if anyone is interested.
_________________
http://tintinplusplus.github.io/
Back to top
View user's profile Send private message
PowerGod



Joined: 04 Aug 2014
Posts: 339

PostPosted: Wed Aug 06, 2014 4:41 am    Post subject: Reply with quote

Thank you, very interesting Smile
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3770

PostPosted: Wed Aug 06, 2014 9:05 pm    Post subject: Reply with quote

Look cool, couple of comments:

Quote:
When creating a new session - the state of the current session (all variables, aliases, classes, etc) are passed into that new session.


It's actually the startup session that is inherited from.

Quote:
Forall: For all items in the specified list, execute some command. This command appears to be identical (except for the "goblin" syntax) to the #foreach command.

Forall is on older command that was left in for backward compatibility.

[/quote]
There are also two flow-control commands that can be used to alter the flow of the loops (though they appear to have identical behavior):
[/quote]
#break and #continue have different behaviors. Probably easiest to show with an example.

Code:

#loop {1} {3} {cnt1} {#loop {3} {6} {cnt2} {#showme $cnt1 and $cnt2;#break}}
#loop {1} {3} {cnt1} {#loop {3} {6} {cnt2} {#showme $cnt1 and $cnt2;#continue}}

These will generate different output.

Quote:
I can never remember the syntax and have to look it up each time I write one (they are very nonstandard).

The [%*] is a regular expression. [(.*)] works as well. More restrictive regex can be used.

Quote:
Unfortunately, the syntax is very difficult and tricky to debug.

The #run command solves some of the issues with #script, though the interface options between sessions are lacking. Lacking time and motivation to fix these issues at the moment.

Quote:
it will not ever display errors or warnings when reading your code.

People tend to take the advantages of tintin's leniency for granted, don't think you can have one without the other.

Quote:
#var {myvar} (myvarvalue);

Braces () and quotes "" are only part of the #math and related commands (which use #math), and are no integral part of tt++. There are no strings as tt++ is typeless.

Quote:
Debugging Techniques

Might want to mention the #debug command.


Pretty cool resource all in all. Smile
Back to top
View user's profile Send private message Send e-mail
PowerGod



Joined: 04 Aug 2014
Posts: 339

PostPosted: Sun Aug 10, 2014 8:41 am    Post subject: Reply with quote

In "Saving Class Data" it tells
Code:
The structure of the command file is not retained and therefore any formatting or comments are completely lost.


But actually not every comment is lost, just the ones OUTSIDE an object.
For example the comments inside Aliases or Actions are kept.
Back to top
View user's profile Send private message
atraeyu



Joined: 12 Dec 2007
Posts: 165

PostPosted: Sat Oct 04, 2014 6:45 pm    Post subject: Reply with quote

Sorry, I posted this thread initially under a different account. Was really me. Smile
FYI, it's been updated, and the unofficial docs are now hosted on read the docs and built using sphinx, here's the links:


http://tintinplusplus.github.io/
http://github.com/tintinplusplus/
http://tintinplusplus-unoffical-documentation.readthedocs.org/
Back to top
View user's profile Send private message AIM Address
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3770

PostPosted: Sun Oct 05, 2014 1:12 pm    Post subject: Reply with quote

Giving it a quick through with some feedback,

#GTS should probably be #gts as it's case sensitive. #tickers don't work in gts, not many differences with a normal session though.

Data types: Nested variables and tables are one and the same. A list is a table with in order numeric keys.

White space is alright as long as it's used outside the braces. Following should work:
Code:

#VAR {V1}
{
    {N1}
    {
        {N2}{VALUE}
    }
}

Note the braces around V1.

Tables and nested variables are the same, though when using braces you're working on the lowest level and are directly assigning. You could for example use:

#var {bla.bli} {{x}{1}{y}{4}}

opposed to:

#var bla.bli.x 1
#var bla.bli.y 4

You can pull the values using wildcards:

#foreach {$bla.bli[%*]} {tmp} {#showme $tmp}

You can also look up a value by index:

#showme Index 1: $bla.bli[+1]
#showme Index 2: $bla.bli[+2]

A negative index starts from the end of the table and works backward:

#showme Index 2: $bla.bli[-1]
#showme Index 1: $bla.bli[-2]

Command Files: Might want to mention #class {name} kill

Loops: Might want to mention that %* is a tintin regular expression and that other expressions can be used.

Mapping

Quote:
If our map file is empty, the goto command will create the first room in the map.

Room #1 is created automatically, goto only creates new rooms if you use the optional "dig" argument.

Quote:

Setting a larger height for the top split results in additional empty rows being displayed, but not a larger map display area.

Incorrect, though you need to increase the height by 3 to create enough space for an additional room, so split 19 1 will get you a larger map.

Quote:

After creating the splits, the buffer window is drawn differently than before

Not quite, the terminal's scrollback will stop working because of the use of a vt102 scrolling region, but tintin's scrollback will still work. tintin has its own scrollback buffer which can be accessed with the #buffer and #grep commands.

Quote:

If you move around, you’ll notice that the map is not updated

Static is disabled by default.

Might want to discussing using netcat to display maps.
http://tintin.sourceforge.net/board/viewtopic.php?p=5739&highlight=#5739


All in all awesome documentation, should be helpful to many people.
Back to top
View user's profile Send private message Send e-mail
atraeyu



Joined: 12 Dec 2007
Posts: 165

PostPosted: Sun Oct 05, 2014 5:26 pm    Post subject: Reply with quote

Thanks Scandum, will update with your corrections. Currently working on a way to add per-page discussions so corrections, discussions, suggestions, etc, can be attached as a 'discussion' directly to each page.
Back to top
View user's profile Send private message AIM Address
ixle



Joined: 15 Sep 2011
Posts: 158
Location: United States

PostPosted: Sun Oct 19, 2014 3:51 pm    Post subject: Reply with quote

Keep up the work on modular scripting. It's been a thing I've wanted to do for a while now. If I ever get time I'll work on updating and converting my Aardwolf-TinTin stuff to it.
Back to top
View user's profile Send private message
PowerGod



Joined: 04 Aug 2014
Posts: 339

PostPosted: Mon Oct 20, 2014 1:23 pm    Post subject: Reply with quote

The modules are indeed interesting, I'll have to find the time to have a better look at them
Back to top
View user's profile Send private message
LokiChaos



Joined: 27 Oct 2009
Posts: 61

PostPosted: Mon Oct 20, 2014 10:43 pm    Post subject: Reply with quote

What license is it under? I wasn't able to locate anything regarding the distribution terms in the module repository.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> General Discussion All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
TinTin++ Homepage

Powered by phpBB © 2001, 2002 phpBB Group