Would you like to react to this message? Create an account in a few clicks or log in to continue.

Unterminated comments in include scripts

3 posters

Go down

Unterminated comments in include scripts Empty Unterminated comments in include scripts

Post by eeriegeek Thu Mar 01, 2012 1:17 am

This wasn't even an issue really until recently, but with SkywingvL's release of the Advanced Script Compiler , which has some more careful script checking than the old Bioware compiler, I ran into this. A number of the CEP scripts have comment blocks at the end which are un-terminated, i.e. there is an opening "/*" with no closing "*/". For example:
Code:

/*
    PrintString("+================================================+");
    PrintString("+==========  Builders' Compendium    ==========+");
    PrintString("+===                                          ===+");
    PrintString("+===  A 1st Order of Role-Players' Creation  ===+");
    PrintString("+==========      www.1stOrder.net      ==========+");
    PrintString("+================================================+");
This unclosed comment causes failure to build the including script in the ASC. The ASC may be updated to allow this with a warning, but it would be a good idea to aim for a clean compile of the CEP scripts with this compiler as it's likely a number of PW's may end up using it to circumvent limits in Bioware's compiler. I ran into the too-many-identifiers limit, which compelled me to use the new compiler. I will likely be modifiing the CEP includes locally for this, but if there's a way to get them back into the CEP so the work doesn't have to be repeated that would be great.
eeriegeek
eeriegeek

Posts : 11
Join date : 2012-01-29
Age : 54
Location : 127.0.0.1

http://www.isleclostridia.net

Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by Baragg Thu Mar 01, 2012 6:14 am

Yea, I have seen that before. Odd that whoever wrote those comments did it in such a manner but each scripter has their own flavor.

Baragg

Posts : 43
Join date : 2012-02-12
Location : Vidor, Texas

http://www.smnwn.com

Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by eeriegeek Thu Mar 01, 2012 11:12 am

Actually, this is much less prevelent than I thought. After taking all the scripts out of CEP 2.4 to recompile them, only that one (zep_inc_1st_rp.nss) has an un-terminated comment. It just got included through zep_inc_phenos and caused a number of warnings. So it should be very little work to clean up. The rest of the CEP scripts built pleasantly cleanly.

The only other thing of significance that the ACS pointed out was:

Code:
horse_dm_mount.nss(9): Warning: NSC6017: "oPC" referenced in initialization expression
Which is this line:

Code:
object oPC    = GetLocalObject(oPC,"ITEM_ACTIVATOR");
I think it's a typo, the second oPC was likely supposed to be oHorse, not sure what it does when it runs. A few minor things: the following files had compiled .ncs files with them, although they produced none on this build. Probably leftovers from testing.

Code:
cut_and_paste.ncs
trap_readmecep21.ncs
zep_cw_inc.ncs
zep_inc_craft.ncs

crp_inc_language.ncs
The following include is duplicated and is the only script in cep2_build, probably just a stray.

Code:
crp_inc_control.nss
The following Bioware resources are over written by cep2_crp_s, they appear intentional, but should be clearly noted.

Code:
default.nss
nw_o2_coninclude.nss
x0_i0_treasure.nss

One last thing of note. The CEP has a useful naming convention, i.e. using the zep_ prefix to group the CEP associated functions and help prevent name collisions. It's also useful for working with the CEP products by themselves when mixed with others, such as in temp0. For instance it would be nice to be able to do "ScriptCompiler zep_*.nss" to rebuild the CEP scripts. Quite a few scripts have deviated from this convention over time and it would be nice where possible to try and get them back on course if possible. Here is a list of "non-canon" script names in the 2.4 hak's:

Code:
_on_playerchat.nss
blockdoor.nss
colors_inc.nss
cut_and_paste.nss
cz_realtroll_sp.nss
cz_realtroll_ud.nss
dmts_common_inc.nss
dragon_dmount.nss
dragon_mount.nss
fly_start.nss
fly_stop.nss
open_store.nss
pointthefinger.nss
pointthefingertl.nss
sfps_inc.nss
sfps_on_close.nss
sfps_on_open.nss
sfrm_exit.nss
sparky_inc.nss
spawner_onenter.nss
spawner_onexit.nss
tbx0_banjo01.nss
tbx0_social_conv.nss
tbx0_social_hb.nss
tbx0_social_ud.nss
tk_ai_demilich.nss
wyrmling_convo.nss
wyrmling_death.nss
wyrmling_dismiss.nss
wyrmling_spawn.nss
z217_behold.nss
zmal_pcl_list.nss
Plus a number of scripts for each of these prefixes:

Code:
conv_*
df_*
dm_*
enc_*
horse_*
mali_*
mcs_*
run_*
trap_*
z_*
eeriegeek
eeriegeek

Posts : 11
Join date : 2012-01-29
Age : 54
Location : 127.0.0.1

http://www.isleclostridia.net

Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by Baragg Thu Mar 01, 2012 12:58 pm

Your staying busy aint ya.

Baragg

Posts : 43
Join date : 2012-02-12
Location : Vidor, Texas

http://www.smnwn.com

Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by Guest Fri Jun 29, 2012 11:03 am

Just looking at that Advanced Script Compiler you linked above - the post says its for NWN2.

Guest
Guest


Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by The Amethyst Dragon Sat Jun 30, 2012 3:06 pm

Pstemarie wrote:Just looking at that Advanced Script Compiler you linked above - the post says its for NWN2.
It also works for NWN, and it's used to replace the default compiler if you are using NWNTX (virusman's Neverwinter Nights Toolset Extender).
The Amethyst Dragon
The Amethyst Dragon
Custom Content Wyrm: CEP 2.60+

Posts : 103
Join date : 2012-01-21
Age : 48
Location : lLoc = GetLocation(oDragon);

http://www.amethyst-dragon.com/nwn

Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by Guest Sat Jun 30, 2012 4:14 pm

The Amethyst Dragon wrote:
Pstemarie wrote:Just looking at that Advanced Script Compiler you linked above - the post says its for NWN2.
It also works for NWN, and it's used to replace the default compiler if you are using NWNTX (virusman's Neverwinter Nights Toolset Extender).

Thanks for the clarification. I've always used the PRC script compiler when the toolset's compiler couldn't handle things anymore. I don't use NWNTX as its not well documented - at least that I could find - and appears quite intimidating.

Guest
Guest


Back to top Go down

Unterminated comments in include scripts Empty Re: Unterminated comments in include scripts

Post by Sponsored content


Sponsored content


Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum