Code: Select all
<!-- ; Use in <OnUpdate with AU_AmmoBoxHandler in <OnFireWeapon> -->
And a semi-colon is still more convenient? Sure, if you have a team of developers to scan through your code and fix your errors on demand.
Code: Select all
<!-- ; Use in <OnUpdate with AU_AmmoBoxHandler in <OnFireWeapon> -->
Okay, I'm going to stop this thread right now.TVR wrote:For future reference, here is a list of all the solutions proposed to deal with the inability for TLisp semi-colon comments to contain XML tags:
a) Continue using semi-colons, and refer to XML tags in riddle only.
b) Wrap all TLisp code in a <[CDATA]> block and never use pointers again.
c) Invent a brand new comment token along with a brand new preprocessor to get rid of them.
d) Atarlost's method, which was apparently too good to be shared in this thread as a solution.
These measures would be laughable, if they weren't also so sincere. To those of you reading this who actually want to avoid the problems mentioned in this thread, and use XML tags in comments, now and without having to lose some other random functionality:
e) Use <!-- and --> to enclose all comments. Compared to semicolon comments, XML comments require an additional token at the end of each comment, but is the only way to include XML tags inside comments without side effects. Consider the extra effort as a form of syntactic salt, tokens of good programming practice.
/thread (That's your cue, Atar)