diff --git a/Build/Compilers/Zandronum/acc.exe b/Build/Compilers/Zandronum/acc.exe index 005a7147a044ad4b144afeab724420e6b2c4fb4f..6286906eecb17c6212e24da3a8341a38f766a83b 100644 Binary files a/Build/Compilers/Zandronum/acc.exe and b/Build/Compilers/Zandronum/acc.exe differ diff --git a/Build/Compilers/Zandronum/zdefs.acs b/Build/Compilers/Zandronum/zdefs.acs index d9f263797794a25da2fb19ef0263fb494294e9ef..d9bfd4953d50f6ae29c1ac4294ff586d33e8da89 100644 --- a/Build/Compilers/Zandronum/zdefs.acs +++ b/Build/Compilers/Zandronum/zdefs.acs @@ -1,4 +1,3 @@ - //************************************************************************** //** //** zdefs.acs @@ -214,6 +213,12 @@ // HUD message. #define HUDMSG_ADDBLEND 0x20000000 +// OR this with one of the above to use the extra alpha parameter +#define HUDMSG_ALPHA 0x10000000 + +// Or this with one of the above to not wrap lines +#define HUDMSG_NOWRAP 0x08000000 + // HUD message layers; these are not flags #define HUDMSG_LAYER_OVERHUD 0x00000000 #define HUDMSG_LAYER_UNDERHUD 0x00001000 @@ -277,6 +282,13 @@ #define APROP_Mass 32 #define APROP_Accuracy 33 #define APROP_Stamina 34 +#define APROP_Height 35 +#define APROP_Radius 36 +#define APROP_Reactiontime 37 +#define APROP_MeleeRange 38 +#define APROP_ViewHeight 39 +#define APROP_AttackZOffset 40 +#define APROP_StencilColor 41 // Render Styles ------------------------------------------------------------ @@ -284,12 +296,14 @@ #define STYLE_Normal 1 // Normal; just copy the image to the screen #define STYLE_Fuzzy 2 // Draw silhouette using "fuzz" effect #define STYLE_SoulTrans 3 // Draw translucent with amount in r_transsouls -#define STYLE_OptFuzzy 4 // Draw as fuzzy or translucent, based on user preference +#define STYLE_OptFuzzy 4 // Draw as fuzzy, translucent or shadow, based on user preference #define STYLE_Stencil 5 // Draw as solid color #define STYLE_Translucent 64 // Draw translucent #define STYLE_Add 65 // Draw additive #define STYLE_Shaded 66 // #define STYLE_TranslucentStencil 67 +#define STYLE_Shadow 68 // Draw dark translucent stencil +#define STYLE_Subtract 69 // Draw subtractive // Properties you can use with GetLevelInfo() ------------------------------- @@ -666,6 +680,46 @@ #define SECSEQ_FULLHEIGHT 3 #define SECSEQ_INTERIOR 4 +// Channels for PlaySound and StopSound + +#define CHAN_AUTO 0 +#define CHAN_WEAPON 1 +#define CHAN_VOICE 2 +#define CHAN_ITEM 3 +#define CHAN_BODY 4 + +// Modifier flags for PlaySound + +#define CHAN_LISTENERZ 8 +#define CHAN_MAYBE_LOCAL 16 +#define CHAN_UI 32 +#define CHAN_NOPAUSE 64 + +// Standard attenuation values for PlaySound + +#define ATTN_NONE 0 // full volume the entire level +#define ATTN_NORM 1.0 +#define ATTN_IDLE 1.001 +#define ATTN_STATIC 3.0 // dimish very rapidly with distance + +// Identifiers for PlayActorSound + +#define SOUND_See 0 +#define SOUND_Attack 1 +#define SOUND_Pain 2 +#define SOUND_Death 3 +#define SOUND_Active 4 +#define SOUND_Use 5 +#define SOUND_Bounce 6 +#define SOUND_WallBounce 7 +#define SOUND_CrushPain 8 +#define SOUND_Howl 9 + +// Flags for SpawnDecal + +#define SDF_ABSANGLE 1 +#define SDF_PERMANENT 2 + // Actor pointer selectors #DEFINE AAPTR_DEFAULT 0 @@ -694,6 +748,22 @@ #DEFINE PTROP_UNSAFEMASTER 2 #DEFINE PTROP_NOSAFEGUARDS PTROP_UNSAFETARGET |PTROP_UNSAFEMASTER +// Line activation flags + +#define SPAC_Cross 1 // when player crosses line +#define SPAC_Use 2 // when player uses line +#define SPAC_MCross 4 // when monster crosses line +#define SPAC_Impact 8 // when projectile hits line +#define SPAC_Push 16 // when player pushes line +#define SPAC_PCross 32 // when projectile crosses line +#define SPAC_UseThrough 64 // when player uses line (doesn't block) +#define SPAC_AnyCross 128 // when anything without the TELEPORT flag crosses the line +#define SPAC_MUse 256 // monsters can use +#define SPAC_MPush 512 // monsters can push +#define SPAC_UseBack 1024 // can be used from the back side + +#define SPAC_None 0 + // ========================================================================== // Skulltag Definitions // ========================================================================== @@ -703,6 +773,26 @@ #define TEAM_RED 1 #define NO_TEAM 2 +// Team properties ---------------------------------------------------------- +#define TPROP_Name 0 +#define TPROP_Score 1 +#define TPROP_IsValid 2 +#define TPROP_NumPlayers 3 +#define TPROP_NumLivePlayers 4 +#define TPROP_TextColor 5 +#define TPROP_PlayerStartNum 6 +#define TPROP_Spread 7 +#define TPROP_Carrier 8 +#define TPROP_Assister 9 +#define TPROP_FragCount 10 +#define TPROP_DeathCount 11 +#define TPROP_WinCount 12 +#define TPROP_PointCount 13 +#define TPROP_ReturnTics 14 +#define TPROP_TeamItem 15 +#define TPROP_WinnerTheme 16 +#define TPROP_LoserTheme 17 + // Skulltag Invasion -------------------------------------------------------- #define IS_WAITINGFORPLAYERS 0 #define IS_FIRSTCOUNTDOWN 1 @@ -766,6 +856,9 @@ #define T_HIGHJUMP 188 #define T_HASTE 189 +// Zandronum database additions --------------------------------------------- +#define DB_ORDER_ASC 0 +#define DB_ORDER_DESC 1 // Events when you have input grabbed @@ -840,6 +933,7 @@ #define CHANGELEVEL_CHANGESKILL 8 #define CHANGELEVEL_NOINTERMISSION 16 #define CHANGELEVEL_RESETHEALTH 32 +#define CHANGELEVEL_PRERAISEWEAPON 64 #define NO_CHANGE 32767.0 @@ -857,6 +951,7 @@ #define BLOCKF_RAILING 64 #define BLOCKF_USE 128 #define BLOCKF_SIGHT 256 +#define BLOCKF_HITSCAN 512 #define FOGP_DENSITY 0 #define FOGP_OUTSIDEDENSITY 1 @@ -869,21 +964,13 @@ #define CSF_NOFAKEFLOORS 1 #define CSF_NOBLOCKALL 2 -#define TPROP_Name 0 -#define TPROP_Score 1 -#define TPROP_IsValid 2 -#define TPROP_NumPlayers 3 -#define TPROP_NumLivePlayers 4 -#define TPROP_TextColor 5 -#define TPROP_PlayerStartNum 6 -#define TPROP_Spread 7 -#define TPROP_Carrier 8 -#define TPROP_Assister 9 -#define TPROP_FragCount 10 -#define TPROP_DeathCount 11 -#define TPROP_WinCount 12 -#define TPROP_PointCount 13 -#define TPROP_ReturnTics 14 -#define TPROP_TeamItem 15 -#define TPROP_WinnerTheme 16 -#define TPROP_LoserTheme 17 \ No newline at end of file +#define FHF_NORANDOMPUFFZ 1 + +// [TP] For GetTimeProperty +#define TM_SECOND 0 +#define TM_MINUTE 1 +#define TM_HOUR 2 +#define TM_DAY 3 +#define TM_MONTH 4 +#define TM_YEAR 5 +#define TM_WEEKDAY 6 diff --git a/Build/Compilers/Zandronum/zspecial.acs b/Build/Compilers/Zandronum/zspecial.acs index 85d10582026c67964c6201bf24ee8011c848f55e..cb97448591bc500b104de2d878036e830a60f441 100644 --- a/Build/Compilers/Zandronum/zspecial.acs +++ b/Build/Compilers/Zandronum/zspecial.acs @@ -14,11 +14,11 @@ special 7:Polyobj_DoorSwing(4), 8:Polyobj_DoorSlide(5), 9:Line_Horizon(0), - 10:Door_Close(2), + 10:Door_Close(2,3), 11:Door_Open(2,3), 12:Door_Raise(3,4), 13:Door_LockedRaise(4,5), - 14:Door_Animated(3), + 14:Door_Animated(3,4), 15:Autosave(0), // 16:Transfer_WallLight 17:Thing_Raise(1), @@ -75,7 +75,7 @@ special 68:Floor_MoveToValueTimes8(4), 69:Ceiling_MoveToValueTimes8(4), 70:Teleport(1,3), - 71:Teleport_NoFog(1,3), + 71:Teleport_NoFog(1,4), 72:ThrustThing(2,4), 73:DamageThing(1,2), 74:Teleport_NewMap(2,3), @@ -83,12 +83,12 @@ special 76:TeleportOther(3), 77:TeleportGroup(5), 78:TeleportInSector(4,5), - + 79:Thing_SetConversation(2), 80:ACS_Execute(2,5), 81:ACS_Suspend(2), 82:ACS_Terminate(2), 83:ACS_LockedExecute(5), - 84:ACS_ExecuteWithResult(1,4), + 84:ACS_ExecuteWithResult(1,5), 85:ACS_LockedExecuteDoor(5), 86:Polyobj_MoveToSpot(3), 87:Polyobj_Stop(1), @@ -101,7 +101,9 @@ special 94:Pillar_BuildAndCrush(4,5), 95:FloorAndCeiling_LowerByValue(3), 96:FloorAndCeiling_RaiseByValue(3), - + 97:Ceiling_LowerAndCrushDist(3,5), + 98:Sector_SetTranslucent(3,4), + 99:Floor_RaiseAndCrushDoom(3,4), // 100:Scroll_Texture_Left // 101:Scroll_Texture_Right // 102:Scroll_Texture_Up @@ -129,7 +131,7 @@ special 130:Thing_Activate(1), 131:Thing_Deactivate(1), 132:Thing_Remove(1), - 133:Thing_Destroy(1,2), + 133:Thing_Destroy(1,3), 134:Thing_Projectile(5), 135:Thing_Spawn(3,4), 136:Thing_ProjectileGravity(5), @@ -146,11 +148,12 @@ special 154:Teleport_NoStop(2, 3), 157:SetGlobalFogParameter(2), // GZDoom only! - 158:FS_Execute(1,4), // GZDoom only! + 158:FS_Execute(1,4), 159:Sector_SetPlaneReflection(3), // GZDoom only! -// 160:Sector_Set3DFloor // GZDoom/Vavoom -// 161:Sector_SetContents // Vavoom +// 160:Sector_Set3DFloor +// 161:Sector_SetContents + 168:Ceiling_CrushAndRaiseDist(3,5), 169:Generic_Crusher2(5), 170:Sector_SetCeilingScale2(3), 171:Sector_SetFloorScale2(3), @@ -209,7 +212,7 @@ special // 225:Scroll_Texture_Offsets, 226:ACS_ExecuteAlways(2,5), // 227:PointPush_SetForce, - 228:Plat_RaiseAndStayTx0(2), + 228:Plat_RaiseAndStayTx0(2,3), 229:Thing_SetGoal(3,4), 230:Plat_UpByValueStayTx(3), 231:Plat_ToggleCeiling(1), @@ -223,7 +226,7 @@ special 239:Floor_RaiseByValueTxTy(3), 240:Floor_RaiseByTexture(2), 241:Floor_LowerToLowestTxTy(2), - 242:Floor_LowerToHighest(3), + 242:Floor_LowerToHighest(3,4), 243:Exit_Normal(1), 244:Exit_Secret(1), 245:Elevator_RaiseToNearest(2), @@ -232,7 +235,7 @@ special 248:HealThing(1,2), 249:Door_CloseWaitOpen(3, 4), 250:Floor_Donut(3), - 251:FloorAndCeiling_LowerRaise(3), + 251:FloorAndCeiling_LowerRaise(3,4), 252:Ceiling_RaiseToNearest(2), 253:Ceiling_LowerToLowest(2), 254:Ceiling_LowerToFloor(2), @@ -250,7 +253,7 @@ special -9:GetActorVelX(1), -10:GetActorVelY(1), -11:GetActorVelZ(1), - -12:SetActivator(1), + -12:SetActivator(1,2), -13:SetActivatorToTarget(1), -14:GetActorViewHeight(1), -15:GetChar(2), @@ -273,7 +276,53 @@ special -32:SoundSequenceOnPolyobj(2), -33:GetPolyobjX(1), -34:GetPolyobjY(1), + -35:CheckSight(3), + -36:SpawnForced(4,6), + -37:AnnouncerSound(2), + -38:SetPointer(2,4), + -39:ACS_NamedExecute(2,5), + -40:ACS_NamedSuspend(2), + -41:ACS_NamedTerminate(2), + -42:ACS_NamedLockedExecute(5), + -43:ACS_NamedLockedExecuteDoor(5), + -44:ACS_NamedExecuteWithResult(1,5), -45:ACS_NamedExecuteAlways(2,5), + -46:UniqueTID(0,2), + -47:IsTIDUsed(1), + -48:Sqrt(1), + -49:FixedSqrt(1), + -50:VectorLength(2), + -51:SetHUDClipRect(4,5), + -52:SetHUDWrapWidth(1), + -53:SetCVar(2), + -54:GetUserCVar(2), + -55:SetUserCVar(3), + -56:GetCVarString(1), + -57:SetCVarString(2), + -58:GetUserCVarString(2), + -59:SetUserCVarString(3), + -60:LineAttack(4,8), + -61:PlaySound(2,6), + -62:StopSound(1,2), + -63:strcmp(2,3), + -64:stricmp(2,3), + -64:strcasecmp(2,3), // an alias for stricmp + -65:StrLeft(2), + -66:StrRight(2), + -67:StrMid(3), + -68:GetActorClass(1), + -69:GetWeapon(0), + -70:SoundVolume(3), + -71:PlayActorSound(2,6), + -72:SpawnDecal(2,6), + -73:CheckFont(1), + -74:DropItem(2,4), + -75:CheckFlag(2), + -76:SetLineActivation(2), + -77:GetLineActivation(1), + -78:GetActorPowerupTics(2), + + // Zandronum's -100:ResetMap(0), -101:PlayerIsSpectator(1), -102:ConsolePlayerNumber(0), @@ -281,6 +330,33 @@ special -104:GetPlayerLivesLeft(1), -105:SetPlayerLivesLeft(2), -106:KickFromGame(2), - -19620:GetTeamScore(1), //Zdaemon + -107:GetGamemodeState(0), + -108:SetDBEntry(3), + -109:GetDBEntry(2), + -110:SetDBEntryString(3), + -111:GetDBEntryString(2), + -112:IncrementDBEntry(3), + -113:PlayerIsLoggedIn(1), + -114:GetPlayerAccountName(1), + -115:SortDBEntries(4), + -116:CountDBResults(1), + -117:FreeDBResults(1), + -118:GetDBResultKeyString(2), + -119:GetDBResultValueString(2), + -120:GetDBResultValue(2), + -121:GetDBEntryRank(3), + -122:RequestScriptPuke(1,5), + -123:BeginDBTransaction(0), + -124:EndDBTransaction(0), + -125:GetDBEntries(1), + -126:NamedRequestScriptPuke(1,5), + -127:SystemTime(0), + -128:GetTimeProperty(2,3), + -129:Strftime(2,3), + + // ZDaemon's + -19260:GetTeamScore(1), + -19261:SetTeamScore(2), + -100000:__EndOfList__(10); - //-1000:__EndOfList__(10); \ No newline at end of file + diff --git a/Build/Scripting/ZDoom_ACS.cfg b/Build/Scripting/ZDoom_ACS.cfg index 618c40c6f8047ae933a22309f7730959f2b2a96f..5b008f76aadf0a3f1c27c4d61d4f9a64a7a88bcb 100644 --- a/Build/Scripting/ZDoom_ACS.cfg +++ b/Build/Scripting/ZDoom_ACS.cfg @@ -57,16 +57,16 @@ keywords ACS_Suspend = "ACS_Suspend(script, map)"; ACS_Terminate = "ACS_Terminate(script, map)"; ActivatorSound = "void ActivatorSound(str sound, int volume)"; - ActivatorTID = "int ActivatorTID(void)"; + ActivatorTID = "int ActivatorTID()"; AmbientSound = "void AmbientSound(str sound, int volume)"; //AnnouncerSound = "void AnnouncerSound(str sound, int flags)"; - Autosave = "Autosave(void)"; + Autosave = "Autosave()"; //BlueCount = "BlueCount()"; //BlueReturn = "Script expression BlueReturn"; //BlueScore = "BlueScore()"; //BlueTeamCount = "BlueTeamCount()"; //BlueTeamScore = "BlueTeamScore()"; - CancelFade = "void CancelFade(void)\nIf either FadeTo or FadeRange is currently in progress,\nCancelFade stops it and turns off the palette flash."; + CancelFade = "void CancelFade()\nIf either FadeTo or FadeRange is currently in progress,\nCancelFade stops it and turns off the palette flash."; CanRaiseActor = "bool CanRaiseActor(int tid)\nChecks to see if the actor or actors with the specified tid are viable for resurrection.\nIf tid is 0, the check is done on the activator of the script."; Ceiling_CrushAndRaise = "Ceiling_CrushAndRaise(tag, speed, crush, crushmode)"; Ceiling_CrushAndRaiseA = "Ceiling_CrushAndRaiseA(tag, dspeed, uspeed, crush, crushmode)"; @@ -116,8 +116,8 @@ keywords ClassifyActor = "int ClassifyActor(int tid)"; ClearActorInventory = "void ClearActorInventory(int tid)\nThis function clears the specified actor's inventory."; ClearForceField = "ClearForceField(tag)"; - ClearInventory = "void ClearInventory(void)\nClears the player's inventory of weapons, ammo, armor and usable items."; - ClearLineSpecial = "void ClearLineSpecial(void)\nClears the special of the line that activated the script."; + ClearInventory = "void ClearInventory()\nClears the player's inventory of weapons, ammo, armor and usable items."; + ClearLineSpecial = "void ClearLineSpecial()\nClears the special of the line that activated the script."; //ConsoleCommand = "void ConsoleCommand(str command)"; Cos = "fixed Cos(int angle)"; CreateTranslation = "void CreateTranslation(int transnumber, a:b=c:d, ...)"; @@ -168,10 +168,10 @@ keywords FloorAndCeiling_LowerByValue = "FloorAndCeiling_LowerByValue(tag, speed, height)"; FloorAndCeiling_LowerRaise = "FloorAndCeiling_LowerRaise(tag, fspeed, cspeed, boomemu)"; FloorAndCeiling_RaiseByValue = "FloorAndCeiling_RaiseByValue(tag, speed, height)"; - ForceField = "ForceField(void)"; + ForceField = "ForceField()"; FS_Execute = "FS_Execute(script, side, keynum, message)"; - GameSkill = "int GameSkill(void)"; - GameType = "int GameType(void)"; + GameSkill = "int GameSkill()"; + GameType = "int GameType()"; Generic_Ceiling = "Generic_Ceiling(tag, speed, height, target, flag)"; Generic_Crusher = "Generic_Crusher(tag, dspeed, uspeed, silent, crush)"; Generic_Crusher2 = "Generic_Crusher2(tag, dspeed, uspeed, silent, crush)"; @@ -206,7 +206,7 @@ keywords //GetInvasionWave = "GetInvasionWave()"; GetLevelInfo = "int GetLevelInfo(int levelinfo)"; GetLineActivation = "int GetLineActivation(int lineid)\nlineid: The id of the line of which to get the activation flags.\nReturns SPAC flags as a bitfield"; - GetLineRowOffset = "int GetLineRowOffset(void)"; + GetLineRowOffset = "int GetLineRowOffset()"; GetLineUDMFFixed = "fixed GetLineUDMFFixed(int lineid, str key)"; GetLineUDMFInt = "int GetLineUDMFInt(int lineid, str key)"; GetMaxInventory = "int GetMaxInventory(int tid, str inventory)"; @@ -214,8 +214,8 @@ keywords GetPlayerInput = "int GetPlayerInput(int player, int input)"; GetPolyobjX = "fixed GetPolyobjX(int polyid)"; GetPolyobjY = "fixed GetPolyobjY(int polyid)"; - GetScreenHeight = "int GetScreenHeight(void)"; - GetScreenWidth = "int GetScreenWidth(void)"; + GetScreenHeight = "int GetScreenHeight()"; + GetScreenWidth = "int GetScreenWidth()"; GetSectorCeilingZ = "int GetSectorCeilingZ(int tag, int x, int y)"; GetSectorFloorZ = "fixed GetSectorFloorZ(int tag, int x, int y)"; GetSectorLightLevel = "int GetSectorLightLevel(int tag)"; @@ -223,22 +223,22 @@ keywords GetSectorUDMFInt = "int GetSectorUDMFInt(int tag, str key)"; GetSideUDMFFixed = "fixed GetSideUDMFFixed(int lineid, bool side, str key)"; GetSideUDMFInt = "int GetSideUDMFInt(int lineid, bool side, str key)"; - GetSigilPieces = "int GetSigilPieces(void)\nReturns the number of Sigil pieces that are held by the player"; + GetSigilPieces = "int GetSigilPieces()\nReturns the number of Sigil pieces that are held by the player"; GetThingUDMFFixed = "fixed GetThingUDMFFixed(int thingid, str key)"; GetThingUDMFInt = "int GetThingUDMFInt(int thingid, str key)"; GetUserArray = "void GetUserArray(int tid, str name, int pos)"; GetUserCVar = "int GetUserCVar(int playernumber, str cvar)"; GetUserCVarString = "str GetUserCVarString(int playernumber, str cvar)"; GetUserVariable = "int GetUserVariable(int tid, str name)"; - GetWeapon = "str GetWeapon(void)\nReturns the class name of the weapon currently equipped by the player as a string"; + GetWeapon = "str GetWeapon()\nReturns the class name of the weapon currently equipped by the player as a string"; GiveActorInventory = "void GiveActorInventory(int tid, str inventory_item, int amount)\nThis function will give the amount of items to the specifed actor.\nThis function does not treat tid 0 as the activator of the script"; GiveInventory = "void GiveInventory(str inventory_item, int amount)\nThis function will give the number of items specified to the activator."; GlassBreak = "GlassBreak(dontspawnjunk)"; HealThing = "HealThing(amount)"; HudMessage = "void hudmessage(s:text; int type, int id, int color, fixed x, fixed y, fixed holdTime)"; HudMessageBold = "void HudMessageBold(s:text; int type, int id, int color, fixed x, fixed y, fixed holdTime)"; - //IsMultiplayer = "int IsMultiplayer(void)"; - //IsOneFlagCTF = "int IsOneFlagCTF(void)"; + //IsMultiplayer = "int IsMultiplayer()"; + //IsOneFlagCTF = "int IsOneFlagCTF()"; IsPointerEqual = "bool IsPointerEqual(int ptr_select1, int ptr_select2[, int tid1[, int tid2]])"; IsTIDUsed = "bool IsTIDUsed(int tid)"; Light_ChangeToValue = "Light_ChangeToValue(tag, value)"; @@ -260,7 +260,7 @@ keywords Line_SetPortalTarget = "Line_SetPortalTarget(sourcelineid, targetlineid)"; Line_SetTextureOffset = "Line_SetTextureOffset(lineid, x, y, side, flags)"; Line_SetTextureScale = "Line_SetTextureScale(lineid, x, y, side, flags)"; - LineSide = "int LineSide(void)"; + LineSide = "int LineSide()"; LocalAmbientSound = "void LocalAmbientSound(str sound, int volume)"; LocalSetMusic = "void LocalSetMusic(str song[, int order[, int unused]])"; Log = "void Log(type:expression)\nLog will print something in the log area of the screen (top left), as well as logging it to the console.\nIt uses the same parameter format as the Print function."; @@ -286,11 +286,11 @@ keywords Plat_UpWaitDownStay = "Plat_UpWaitDownStay(tag, speed, delay)"; PlayActorSound = "void PlayActorSound(int tid, int sound, int channel, fixed volume, bool looping, fixed attenuation)"; PlayerClass = "int PlayerClass(int playernumber)"; - PlayerCount = "int PlayerCount(void)\nReturns the number of players currently in the game"; - PlayerFrags = "int PlayerFrags(void)"; + PlayerCount = "int PlayerCount()\nReturns the number of players currently in the game"; + PlayerFrags = "int PlayerFrags()"; PlayerInGame = "bool PlayerInGame(int playernumber)\nReturns true if the player [0..7] is in the game"; PlayerIsBot = "bool PlayerIsBot(int playernumber)\nReturns TRUE if the player [0..7] is a bot and FALSE if not"; - PlayerNumber = "int PlayerNumber(void)\nReturns the player number for the player who activated the script, starting at 0.\nFor scripts that were not activated by a player, PlayerNumber will return -1."; + PlayerNumber = "int PlayerNumber()\nReturns the player number for the player who activated the script, starting at 0.\nFor scripts that were not activated by a player, PlayerNumber will return -1."; PlaySound = "void PlaySound(int tid, str sound[, int channel = CHAN_BODY[, fixed volume = 1.0[, bool looping = false[, fixed attenuation = ATTN_NORM]]]])"; Polyobj_DoorSlide = "Polyobj_DoorSlide(po, speed, angle, dist, delay)"; Polyobj_DoorSwing = "Polyobj_DoorSwing(po, speed, angle, delay)"; @@ -425,7 +425,7 @@ keywords TakeActorInventory = "void TakeActorInventory(int tid, str inventory_item, int amount)\nThis function will take the amount of items from the specified actor.\nTakeActorInventory can remove items that are flagged as undroppable."; TakeInventory = "void TakeInventory(str inventory_item, int amount)\nThis function will take the number of items specified from the activator.\nTakeInventory can remove items that are flagged as undroppable."; Teleport = "Teleport(tid, tag, nosourcefog)"; - Teleport_EndGame = "Teleport_EndGame(void)"; + Teleport_EndGame = "Teleport_EndGame()"; Teleport_NewMap = "Teleport_NewMap(map, pos, face)"; Teleport_NoFog = "Teleport_NoFog(tid, useangle, tag)"; Teleport_NoStop = "Teleport_NoStop(tid, tag, nofog)"; @@ -463,7 +463,7 @@ keywords ThingSound = "void ThingSound(int tid, str sound, int volume)\nPlays a sound at a thing.\nThis is a point sound, so anyone far away will not hear it as loudly"; ThrustThing = "ThrustThing(angle, force, nolimit, tid)"; ThrustThingZ = "ThrustThingZ(tid, speed, up_or_down, add_or_set)"; - Timer = "int Timer(void)"; + Timer = "int Timer()"; TranslucentLine = "TranslucentLine(lineid, amount, additive, moreflags)"; UniqueTID = "int UniqueTID([int tid[, int limit]])"; UnMorphActor = "int UnMorphActor(int tid[, bool force])"; diff --git a/Build/Scripting/Zandronum_ACS.cfg b/Build/Scripting/Zandronum_ACS.cfg index cbb4c53d561cee529450c3e86920694cdbce6e05..903f63400c602f93144643ffd231e70c68da27e6 100644 --- a/Build/Scripting/Zandronum_ACS.cfg +++ b/Build/Scripting/Zandronum_ACS.cfg @@ -22,51 +22,65 @@ arrayopen = "["; arrayclose = "]"; argumentdelimiter = ","; terminator = ";"; +extrawordchars = "#"; // Extra characters to be treated as a part of a word by the Script Editor keywordhelp = "http://www.zdoom.org/wiki/index.php?title=%K"; snippetsdir = "acs"; scripttype = 1; //0 = unknown script, 1 = acc, 2 = modeldef, 3 = decorate keywords { - #Define = "#Define identifier expression"; - #EncryptStrings = "#EncryptStrings"; - #Import = "#Import"; - #Include = "#Include"; - #Library = "#Library"; - #LibDefine = "#LibDefine identifier expression"; + #define = "#Define identifier expression"; + #encryptstrings = "#EncryptStrings"; + #import = "#Import"; + #include = "#Include"; + #libdefine = "#LibDefine identifier expression"; + #library = "#Library"; #NoCompact = "#NoCompact"; #NoWadAuthor = "#NoWadAuthor"; #WadAuthor = "#WadAuthor"; + #region = "#region block"; + #endregion = "end of #region block"; ACS_Execute = "ACS_Execute(script, map, arg1, arg2, arg3)"; ACS_ExecuteAlways = "ACS_ExecuteAlways(script, map, arg1, arg2, arg3)"; - ACS_ExecuteWait = "ACS_ExecuteWait(script, map, arg1, arg2, arg3)"; - ACS_ExecuteWithResult = "ACS_ExecuteWithResult(script, s_arg1, s_arg2, s_arg3)"; + ACS_ExecuteWait = "void ACS_ExecuteWait(int script, int unused, int arg1, int arg2, int arg3)"; + ACS_ExecuteWithResult = "ACS_ExecuteWithResult(script, arg1, arg2, arg3)"; ACS_LockedExecute = "ACS_LockedExecute(script, map, arg1, arg2, lock)"; ACS_LockedExecuteDoor = "ACS_LockedExecuteDoor(script, map, arg1, arg2, lock)"; + ACS_NamedExecute = "bool ACS_NamedExecute(str script, int map, int arg1, int arg2, int arg3)"; + ACS_NamedExecuteAlways = "bool ACS_NamedExecuteAlways(str script, int map, int arg1, int arg2, int arg3)"; + ACS_NamedExecuteWait = "void ACS_NamedExecuteWait(str script, int unused, int arg1, int arg2, int arg3)"; + ACS_NamedExecuteWithResult = "int ACS_NamedExecuteWithResult(str script, int arg1, int arg2, int arg3, int arg4)"; + ACS_NamedLockedExecute = "bool ACS_NamedLockedExecute(str script, int map, int arg1, int arg2, int lock)"; + ACS_NamedLockedExecuteDoor = "bool ACS_NamedLockedExecuteDoor(str script, int map, int arg1, int arg2, int lock)"; + ACS_NamedSuspend = "bool ACS_NamedSuspend(str script, int map)"; + ACS_NamedTerminate = "bool ACS_NamedTerminate(str script, int map)"; ACS_Suspend = "ACS_Suspend(script, map)"; ACS_Terminate = "ACS_Terminate(script, map)"; - ActivatorSound = "ActivatorSound(name, volume)"; - ActivatorTID = "ActivatorTID()"; - AmbientSound = "AmbientSound(name, volume)"; + ActivatorSound = "void ActivatorSound(str sound, int volume)"; + ActivatorTID = "int ActivatorTID()"; + AmbientSound = "void AmbientSound(str sound, int volume)"; + AnnouncerSound = "void AnnouncerSound(str sound, int flags)"; Autosave = "Autosave()"; - BlueTeamCount = "BlueTeamCount()"; - BlueTeamScore = "BlueTeamScore()"; - Bool = "Bool expression"; - Break = "Break"; - Return = "Return"; - CancelFade = "CancelFade()"; - Case = "Case expression:"; - Ceiling_CrushAndRaise = "Ceiling_CrushAndRaise(tag, speed, crush)"; - Ceiling_CrushAndRaiseA = "Ceiling_CrushAndRaiseA(tag, dspeed, uspeed, crush)"; - Ceiling_CrushAndRaiseSilentA = "Ceiling_CrushAndRaiseSilentA(tag, dspeed, uspeed, crush)"; - Ceiling_CrushRaiseAndStay = "Ceiling_CrushRaiseAndStay(tag, speed, crush)"; - Ceiling_CrushRaiseAndStayA = "Ceiling_CrushRaiseAndStayA(tag, dspeed, uspeed, crush)"; - Ceiling_CrushRaiseAndStaySilA = "Ceiling_CrushRaiseAndStaySilA(tag, dspeed, uspeed, crush)"; + BeginDBTransaction = "void BeginDBTransaction()"; + //BlueCount = "BlueCount()"; + //BlueReturn = "Script expression BlueReturn"; + //BlueScore = "BlueScore()"; + //BlueTeamCount = "BlueTeamCount()"; + //BlueTeamScore = "BlueTeamScore()"; + CancelFade = "void CancelFade()\nIf either FadeTo or FadeRange is currently in progress,\nCancelFade stops it and turns off the palette flash."; + Ceiling_CrushAndRaise = "Ceiling_CrushAndRaise(tag, speed, crush, crushmode)"; + Ceiling_CrushAndRaiseA = "Ceiling_CrushAndRaiseA(tag, dspeed, uspeed, crush, crushmode)"; + Ceiling_CrushAndRaiseDist = "Ceiling_CrushAndRaiseDist(tag, dist, speed, damage, crushmode)"; + Ceiling_CrushAndRaiseSilentA = "Ceiling_CrushAndRaiseSilentA(tag, dspeed, uspeed, crush, crushmode)"; + Ceiling_CrushRaiseAndStay = "Ceiling_CrushRaiseAndStay(tag, speed, crush, crushmode)"; + Ceiling_CrushRaiseAndStayA = "Ceiling_CrushRaiseAndStayA(tag, dspeed, uspeed, crush, crushmode)"; + Ceiling_CrushRaiseAndStaySilA = "Ceiling_CrushRaiseAndStaySilA(tag, dspeed, uspeed, crush, crushmode)"; Ceiling_CrushStop = "Ceiling_CrushStop(tag)"; - Ceiling_LowerAndCrush = "Ceiling_LowerAndCrush(tag, speed, crush)"; + Ceiling_LowerAndCrush = "Ceiling_LowerAndCrush(tag, speed, crush, crushmode)"; + Ceiling_LowerAndCrushDist = "Ceiling_LowerAndCrushDist(tag, speed, crush, dist, crushmode)"; Ceiling_LowerByValue = "Ceiling_LowerByValue(tag, speed, height)"; Ceiling_LowerByValueTimes8 = "Ceiling_LowerByValueTimes8(tag, speed, height)"; - Ceiling_LowerInstant = "Ceiling_LowerInstant(tag, arg1, height)"; + Ceiling_LowerInstant = "Ceiling_LowerInstant(tag, unused, height)"; Ceiling_LowerToFloor = "Ceiling_LowerToFloor(tag, speed)"; Ceiling_LowerToHighestFloor = "Ceiling_LowerToHighestFloor(tag, speed)"; Ceiling_LowerToLowest = "Ceiling_LowerToLowest(tag, speed)"; @@ -74,72 +88,74 @@ keywords Ceiling_MoveToValueTimes8 = "Ceiling_MoveToValueTimes8(tag, speed, height, neg)"; Ceiling_RaiseByValue = "Ceiling_RaiseByValue(tag, speed, height)"; Ceiling_RaiseByValueTimes8 = "Ceiling_RaiseByValueTimes8(tag, speed, height)"; - Ceiling_RaiseInstant = "Ceiling_RaiseInstant(tag, arg1, height)"; + Ceiling_RaiseInstant = "Ceiling_RaiseInstant(tag, unused, height)"; Ceiling_RaiseToNearest = "Ceiling_RaiseToNearest(tag, speed)"; Ceiling_Waggle = "Ceiling_Waggle(tag, amp, freq, offset, time)"; ChangeCamera = "ChangeCamera(tid, who, revert)"; - ChangeCeiling = "ChangeCeiling(tag, flat)"; - ChangeFloor = "ChangeFloor(tag, flat)"; - ChangeLevel = "ChangeLevel(mapname, position, flags, skill)"; + ChangeCeiling = "void ChangeCeiling(int tag, str flatname)"; + ChangeFloor = "void ChangeFloor(int tag, str flatname)"; + ChangeLevel = "void ChangeLevel(str mapname, int position, int flags[, int skill])\nChanges to a new map, places the player at the specified start spot, and optionally changes the skill level at the same time."; ChangeSkill = "ChangeSkill(skill)"; - CheckActorCeilingTexture = "CheckActorCeilingTexture(tid, texture)"; - CheckActorClass = "CheckActorClass(tid, class)"; - CheckActorFloorTexture = "CheckActorFloorTexture(tid, texture)"; - CheckActorInventory = "CheckActorInventory(tid, type)"; - CheckActorProperty = "CheckActorProperty(tid, property, value)"; - CheckInventory = "CheckInventory(type)"; - CheckPlayerCamera = "CheckPlayerCamera(player)"; - CheckWeapon = "CheckWeapon(weapon)"; - ClassifyActor = "ClassifyActor(tid)"; - ClearActorInventory = "ClearActorInventory(tid)"; - ClearForceField = "ClearForceField()"; - ClearInventory = "ClearInventory()"; - ClearLineSpecial = "ClearLineSpecial()"; - ConsoleCommand = "ConsoleCommand(command)"; - Const = "Const"; - Continue = "Continue"; - cos = "cos(angle)"; - CreateTranslation = "CreateTranslation(transnumber, translation, translation, translation, ...)"; - DamageThing = "DamageThing(amount)"; - Death = "Script expression Death"; - Default = "Default:"; - Delay = "Delay(tics)"; - Disconnect = "Script expression Disconnect"; - Do = "Do"; - Door_Animated = "Door_Animated(tag, speed, delay)"; - Door_Close = "Door_Close(tag, speed)"; - Door_CloseWaitOpen = "Door_CloseWaitOpen(tag, speed, delay)"; - Door_LockedRaise = "Door_LockedRaise(tag, speed, delay, lock)"; - Door_Open = "Door_Open(tag, speed)"; - Door_Raise = "Door_Raise(tag, speed, delay)"; + ChangeSky = "void ChangeSky(str sky1, str sky2)\nChanges the sky texture to sky1 and the second sky texture to sky2.\nBoth textures must be the same height if doublesky is enabled.\nYou may also use any flat, pname, sprite or internal graphic (such as TITLEPIC) in place of an actual texture.\nUseful in conjunction with SetSkyScrollSpeed."; + CheckActorCeilingTexture = "bool CheckActorCeilingTexture(int tid, str texture)"; + CheckActorClass = "bool CheckActorClass(int tid, str class)"; + CheckActorFloorTexture = "bool CheckActorFloorTexture(int tid, str texture)"; + CheckActorInventory = "int CheckActorInventory(int tid, str inventory_item)\nChecks the given actor's inventory for the item specified by inventory_item"; + CheckActorProperty = "bool CheckActorProperty(int tid, int property, [int|float|str] value)"; + CheckFlag = "bool CheckFlag(int tid, str flag)\nChecks to see if the actor with the matching tid has the specified actor flag set.\nIf tid is 0, the check is performed on the activator of the script."; + CheckFont = "bool CheckFont(str fontname)"; + CheckInventory = "int CheckInventory(str inventory_item)\nChecks the inventory of the actor who activated the script for the item specified by inventory_item"; + CheckPlayerCamera = "int CheckPlayerCamera(int player)"; + CheckSight = "bool CheckSight(int source, int dest, int flags)"; + CheckWeapon = "bool CheckWeapon(str weapon)\nChecks if player's active weapon is the weapon with specified class name."; + ClassifyActor = "int ClassifyActor(int tid)"; + ClearActorInventory = "void ClearActorInventory(int tid)\nThis function clears the specified actor's inventory."; + ClearForceField = "ClearForceField(tag)"; + ClearInventory = "void ClearInventory()\nClears the player's inventory of weapons, ammo, armor and usable items."; + ClearLineSpecial = "void ClearLineSpecial()\nClears the special of the line that activated the script."; + //ConsoleCommand = "void ConsoleCommand(str command)"; + ConsolePlayerNumber = "int ConsolePlayerNumber()"; + Cos = "fixed Cos(int angle)"; + CountDBResults = "int CountDBResults(resource results)"; + CreateTranslation = "void CreateTranslation(int transnumber, a:b=c:d, ...)"; + DamageThing = "DamageThing(amount, mod)"; + Delay = "void Delay(int tics)"; + Door_Animated = "Door_Animated(tag, speed, delay, lock)"; + Door_Close = "Door_Close(tag, speed, lighttag)"; + Door_CloseWaitOpen = "Door_CloseWaitOpen(tag, speed, delay, lighttag)"; + Door_LockedRaise = "Door_LockedRaise(tag, speed, delay, lock, lighttag)"; + Door_Open = "Door_Open(tag, speed, lighttag)"; + Door_Raise = "Door_Raise(tag, speed, delay, lighttag)"; + DropItem = "int DropItem(int tid, str item[, int dropamount = -1[, int chance = 256]])\nCauses actors with the matching tid to drop the specified item.\nIf tid is 0, the activator of the script is considered to be the dropper of the item.\nThis works in a similar way to the DropItem actor property.\nThe return value of the function is the number of dropped items."; Elevator_LowerToNearest = "Elevator_LowerToNearest(tag, speed)"; Elevator_MoveToFloor = "Elevator_MoveToFloor(tag, speed)"; Elevator_RaiseToNearest = "Elevator_RaiseToNearest(tag, speed)"; - Else = "Else"; - Enter = "Script expression Enter"; + EndDBTransaction = "void EndDBTransaction()"; Exit_Normal = "Exit_Normal(pos)"; Exit_Secret = "Exit_Secret(pos)"; - FadeRange = "FadeRange(red1, green1, blue1, red2, green2, blue2, amount, seconds)"; - FadeTo = "FadeTo(red, green, blue, amount, seconds)"; - FixedDiv = "FixedDiv(fa, fb)"; - FixedMul = "FixedMul(fa, fb)"; + FadeRange = "void FadeRange(int red1, int green1, int blue1, fixed amount1, int red2, int green2, int blue2, fixed amount2, fixed seconds)\nSets the current flash to the first color set and then fades it to the second color set over the specified number of seconds."; + FadeTo = "void FadeTo(int red, int green, int blue, fixed amount, fixed seconds)\nFades the activator's view from the current palette flash to another one.\nThis will also work if the activator is looking through another viewpoint (using a camera, etc.)."; + FixedDiv = "fixed FixedDiv(int a, int b)"; + FixedMul = "fixed FixedMul(int a, int b)"; + FixedSqrt = "fixed FixedSqrt(fixed number)"; Floor_CrushStop = "Floor_CrushStop(tag)"; Floor_Donut = "Floor_Donut(ptag, pspeed, sspeed)"; Floor_LowerByValue = "Floor_LowerByValue(tag, speed, height)"; Floor_LowerByValueTimes8 = "Floor_LowerByValueTimes8(tag, speed, height)"; - Floor_LowerInstant = "Floor_LowerInstant(tag, arg1, height)"; - Floor_LowerToHighest = "Floor_LowerToHighest(tag, speed, adjust)"; + Floor_LowerInstant = "Floor_LowerInstant(tag, unused, height)"; + Floor_LowerToHighest = "Floor_LowerToHighest(tag, speed, adjust, force_adjust)"; Floor_LowerToLowest = "Floor_LowerToLowest(tag, speed)"; Floor_LowerToLowestTxTy = "Floor_LowerToLowestTxTy(tag, speed)"; Floor_LowerToNearest = "Floor_LowerToNearest(tag, speed)"; Floor_MoveToValue = "Floor_MoveToValue(tag, speed, height, neg)"; Floor_MoveToValueTimes8 = "Floor_MoveToValueTimes8(tag, speed, height, neg)"; - Floor_RaiseAndCrush = "Floor_RaiseAndCrush(tag, speed, crush)"; + Floor_RaiseAndCrush = "Floor_RaiseAndCrush(tag, speed, crush, crushmode)"; + Floor_RaiseAndCrushDoom = "Floor_RaiseAndCrushDoom(tag, speed, crush, crushmode)"; Floor_RaiseByTexture = "Floor_RaiseByTexture(tag, speed)"; Floor_RaiseByValue = "Floor_RaiseByValue(tag, speed, height)"; Floor_RaiseByValueTimes8 = "Floor_RaiseByValueTimes8(tag, speed, height)"; Floor_RaiseByValueTxTy = "Floor_RaiseByValueTxTy(tag, speed, height)"; - Floor_RaiseInstant = "Floor_RaiseInstant(tag, arg1, height)"; + Floor_RaiseInstant = "Floor_RaiseInstant(tag, unused, height)"; Floor_RaiseToHighest = "Floor_RaiseToHighest(tag, speed)"; Floor_RaiseToLowestCeiling = "Floor_RaiseToLowestCeiling(tag, speed)"; Floor_RaiseToNearest = "Floor_RaiseToNearest(tag, speed)"; @@ -147,77 +163,96 @@ keywords Floor_TransferTrigger = "Floor_TransferTrigger(tag)"; Floor_Waggle = "Floor_Waggle(tag, amp, freq, offset, time)"; FloorAndCeiling_LowerByValue = "FloorAndCeiling_LowerByValue(tag, speed, height)"; - FloorAndCeiling_LowerRaise = "FloorAndCeiling_LowerRaise(tag, fspeed, cspeed)"; + FloorAndCeiling_LowerRaise = "FloorAndCeiling_LowerRaise(tag, fspeed, cspeed, boomemu)"; FloorAndCeiling_RaiseByValue = "FloorAndCeiling_RaiseByValue(tag, speed, height)"; - For = "For(initialization, condition, iteration)"; ForceField = "ForceField()"; - Function = "Function Void expression (Void)"; - GameSkill = "GameSkill()"; - GameType = "GameType()"; + FreeDBResults = "void FreeDBResults(int set)"; + FS_Execute = "FS_Execute(script, side, keynum, message)"; + GameSkill = "int GameSkill()"; + GameType = "int GameType()"; Generic_Ceiling = "Generic_Ceiling(tag, speed, height, target, flag)"; Generic_Crusher = "Generic_Crusher(tag, dspeed, uspeed, silent, crush)"; + Generic_Crusher2 = "Generic_Crusher2(tag, dspeed, uspeed, silent, crush)"; Generic_Door = "Generic_Door(tag, speed, kind, delay, lock)"; Generic_Floor = "Generic_Floor(tag, speed, height, target, flags)"; Generic_Lift = "Generic_Lift(tag, speed, delay, type, height)"; Generic_Stairs = "Generic_Stairs(tag, speed, height, flags, reset)"; - GetLevelInfo = "GetLevelInfo(infotype)"; - GetActorAngle = "GetActorAngle(tid)"; - GetActorCeilingZ = "GetActorCeilingZ(tid)"; - GetActorFloorZ = "GetActorFloorZ(tid)"; - GetActorLightLevel = "GetActorLightLevel(tid)"; - GetActorPitch = "GetActorPitch(tid)"; - GetActorProperty = "GetActorProperty(tid, property)"; - GetActorVelX = "GetActorVelX(tid)"; - GetActorVelY = "GetActorVelY(tid)"; - GetActorVelZ = "GetActorVelZ(tid)"; - GetActorViewHeight = "GetActorViewHeight(tid)"; - GetActorX = "GetActorX(tid)"; - GetActorY = "GetActorY(tid)"; - GetActorZ = "GetActorZ(tid)"; - GetAirSupply = "GetAirSupply(playernumber)"; - GetAmmoCapacity = "GetAmmoCapacity(classname)"; - GetArmorType = "GetArmorType(armortype, playernumber)"; - GetChar = "GetChar(string, index)"; - GetCVar = "GetCVar(name)"; - GetInvasionState = "GetInvasionState()"; - GetInvasionWave = "GetInvasionWave()"; - GetPlayerInfo = "GetPlayerInfo(playernumber, infotype)"; - GetLevelInfo = "GetLevelInfo(infotype)"; - GetLineRowOffset = "GetLineRowOffset()"; - GetLineUDMFInt = "GetLineUDMFInt(lineid, fieldname)"; - GetLineUDMFFixed = "GetLineUDMFFixed(lineid, fieldname)"; - GetPlayerInput = "GetPlayerInput(player, input)"; - GetPolyobjX = "GetPolyobjX(po)"; - GetPolyobjY = "GetPolyobjY(po)"; - GetScreenHeight = "GetScreenHeight()"; - GetScreenWidth = "GetScreenWidth()"; - GetSectorCeilingZ = "GetSectorCeilingZ(tag, x, y)"; - GetSectorFloorZ = "GetSectorFloorZ(tag, x, y)"; - GetSectorLightLevel = "GetSectorLightLevel(tag)"; - GetSectorUDMFInt = "GetSectorUDMFInt(tag, fieldname)"; - GetSectorUDMFFixed = "GetSectorUDMFFixed(tag, fieldname)"; - GetSideUDMFInt = "GetSideUDMFInt(lineid, side, fieldname)"; - GetSideUDMFFixed = "GetSideUDMFFixed(lineid, side, fieldname)"; - GetThingUDMFInt = "GetThingUDMFInt(tid, fieldname)"; - GetThingUDMFFixed = "GetThingUDMFFixed(tid, fieldname)"; - GetUserArray = "GetUserArray(tid, name, pos)"; - GetUserVariable = "GetUserVariable(tid, name)"; - GiveActorInventory = "GiveActorInventory(tid, type, amount)"; - GiveInventory = "GiveInventory(type, amount)"; + GetActorAngle = "fixed GetActorAngle(int tid)"; + GetActorCeilingZ = "fixed GetActorCeilingZ(int tid)"; + GetActorClass = "str GetActorClass(int tid)"; + GetActorFloorZ = "fixed GetActorFloorZ(int tid)"; + GetActorLightLevel = "int GetActorLightLevel(int tid)"; + GetActorPitch = "fixed GetActorPitch(int tid)"; + GetActorPowerupTics = "int GetActorPowerupTics(int tid, str powerup)"; + GetActorProperty = "int GetActorProperty(int tid, int property)"; + GetActorVelX = "fixed GetActorVelX(int tid)"; + GetActorVelY = "fixed GetActorVelY(int tid)"; + GetActorVelZ = "fixed GetActorVelZ(int tid)"; + GetActorViewHeight = "fixed GetActorViewHeight(int tid)"; + GetActorX = "fixed GetActorX(int tid)"; + GetActorY = "fixed GetActorY(int tid)"; + GetActorZ = "fixed GetActorZ(int tid)"; + GetAirSupply = "int GetAirSupply(int playernum)"; + GetAmmoCapacity = "int GetAmmoCapacity(str classname)"; + GetArmorType = "int GetArmorType(str armortype, int playernum)"; + GetChar = "int GetChar(str string, int index)"; + GetCVar = "int GetCVar(str cvar)"; + GetCVarString = "str GetCVarString(str cvar)"; + GetDBEntries = "resource GetDBEntries(str namespace)"; + GetDBEntry = "int GetDBEntry(table, variable)"; + GetDBEntryRank = "int GetDBEntryRank(str namespace, str key, int order)"; + GetDBEntryString = "str GetDBEntryString(str namespace, str key)"; + GetDBResultKeyString = "str GetDBResultKeyString(int set, int record)"; + GetDBResultValue = "int GetDBResultValue(int set, int record)"; + GetDBResultValueString = "str GetDBResultValueString(int set, int record)"; + GetGameModeState = "int GetGameModeState()"; + GetInvasionState = "int GetInvasionState()"; + GetInvasionWave = "int GetInvasionWave()"; + GetLevelInfo = "int GetLevelInfo(int levelinfo)"; + GetLineActivation = "int GetLineActivation(int lineid)\nlineid: The id of the line of which to get the activation flags.\nReturns SPAC flags as a bitfield"; + GetLineRowOffset = "int GetLineRowOffset()"; + GetLineUDMFFixed = "fixed GetLineUDMFFixed(int lineid, str key)"; + GetLineUDMFInt = "int GetLineUDMFInt(int lineid, str key)"; + GetPlayerAccountName = "str GetPlayerAccountName(int player)"; + GetPlayerInfo = "int GetPlayerInfo(int playernumber, int playerinfo)"; + GetPlayerInput = "int GetPlayerInput(int player, int input)"; + GetPlayerLivesLeft = "int GetPlayerLivesLeft(int player)"; + GetPolyobjX = "fixed GetPolyobjX(int polyid)"; + GetPolyobjY = "fixed GetPolyobjY(int polyid)"; + GetScreenHeight = "int GetScreenHeight()"; + GetScreenWidth = "int GetScreenWidth()"; + GetSectorCeilingZ = "int GetSectorCeilingZ(int tag, int x, int y)"; + GetSectorFloorZ = "fixed GetSectorFloorZ(int tag, int x, int y)"; + GetSectorLightLevel = "int GetSectorLightLevel(int tag)"; + GetSectorUDMFFixed = "fixed GetSectorUDMFFixed(int tag, str key)"; + GetSectorUDMFInt = "int GetSectorUDMFInt(int tag, str key)"; + GetSideUDMFFixed = "fixed GetSideUDMFFixed(int lineid, bool side, str key)"; + GetSideUDMFInt = "int GetSideUDMFInt(int lineid, bool side, str key)"; + GetSigilPieces = "int GetSigilPieces()\nReturns the number of Sigil pieces that are held by the player"; + GetTeamProperty = "int GetTeamProperty(int team, int prop)"; + GetTimeProperty = "int GetTimeProperty(int timestamp, int which[, bool utc])"; + GetThingUDMFFixed = "fixed GetThingUDMFFixed(int thingid, str key)"; + GetThingUDMFInt = "int GetThingUDMFInt(int thingid, str key)"; + GetUserArray = "void GetUserArray(int tid, str name, int pos)"; + GetUserCVar = "int GetUserCVar(int playernumber, str cvar)"; + GetUserCVarString = "str GetUserCVarString(int playernumber, str cvar)"; + GetUserVariable = "int GetUserVariable(int tid, str name)"; + GetWeapon = "str GetWeapon()\nReturns the class name of the weapon currently equipped by the player as a string"; + GiveActorInventory = "void GiveActorInventory(int tid, str inventory_item, int amount)\nThis function will give the amount of items to the specifed actor.\nThis function does not treat tid 0 as the activator of the script"; + GiveInventory = "void GiveInventory(str inventory_item, int amount)\nThis function will give the number of items specified to the activator."; GlassBreak = "GlassBreak(dontspawnjunk)"; - Global = "Global Int expression:identifier"; - Goto = "Goto"; HealThing = "HealThing(amount)"; - HudMessage = "HudMessage(text; type, id, color, x, y, holdtime)"; - HudMessageBold = "HudMessageBold(text; type, id, color, x, y, holdtime)"; - If = "If(expression)"; - Int = "Int expression"; - IsMultiplayer = "IsMultiplayer()"; - IsOneFlagCTF = "IsOneFlagCTF()"; + HudMessage = "void hudmessage(s:text; int type, int id, int color, fixed x, fixed y, fixed holdTime)"; + HudMessageBold = "void HudMessageBold(s:text; int type, int id, int color, fixed x, fixed y, fixed holdTime)"; + IsMultiplayer = "bool IsMultiplayer()"; + IsOneFlagCTF = "bool IsOneFlagCTF()"; + IncrementDBEntry = "void IncrementDBEntry(str namespace, str key, int amount)"; + IsTIDUsed = "bool IsTIDUsed(int tid)"; + KickFromGame = "bool KickFromGame(int player, str reason)"; Light_ChangeToValue = "Light_ChangeToValue(tag, value)"; Light_Fade = "Light_Fade(tag, value, tics)"; Light_Flicker = "Light_Flicker(tag, upper, lower)"; - Light_ForceLightning = "Light_ForceLightning()"; + Light_ForceLightning = "Light_ForceLightning(mode)"; Light_Glow = "Light_Glow(tag, upper, lower, tics)"; Light_LowerByValue = "Light_LowerByValue(tag, value)"; Light_MaxNeighbor = "Light_MaxNeighbor(tag)"; @@ -226,260 +261,359 @@ keywords Light_Stop = "Light_Stop(tag)"; Light_Strobe = "Light_Strobe(tag, upper, lower, u-tics, l-tics)"; Light_StrobeDoom = "Light_StrobeDoom(tag, u-tics, l-tics)"; - Lightning = "Script expression Lightning"; + LineAttack = "LineAttack(int tid, fixed angle, fixed pitch, int damage[, str pufftype = 'BulletPuff'[, str damagetype = 'None'[, fixed range = 2048[, int flags = 0]]]])\nFires a hitscan attack. If tid is 0, the activator of the script is the source of the attack."; Line_AlignCeiling = "Line_AlignCeiling(lineid, side)"; Line_AlignFloor = "Line_AlignFloor(lineid, side)"; Line_SetBlocking = "Line_SetBlocking(lineid, setflags, clearflags)"; - Line_SetTextureScale = "Line_SetTextureScale(lineid, x, y, side, flags)"; Line_SetTextureOffset = "Line_SetTextureOffset(lineid, x, y, side, flags)"; - LineSide = "LineSide()"; - LocalAmbientSound = "LocalAmbientSound(name, volume)"; - LocalSetMusic = "LocalSetMusic(song, pattern, transition)"; - Log = "Log(type:expression)"; - MorphActor = "MorphActor(tid, playerclass, monsterclass, duration, style, morphflash, unmorphflash)"; - Net = "Script expression Net"; + Line_SetTextureScale = "Line_SetTextureScale(lineid, x, y, side, flags)"; + LineSide = "int LineSide()"; + LocalAmbientSound = "void LocalAmbientSound(str sound, int volume)"; + LocalSetMusic = "void LocalSetMusic(str song[, int order[, int unused]])"; + Log = "void Log(type:expression)\nLog will print something in the log area of the screen (top left), as well as logging it to the console.\nIt uses the same parameter format as the Print function."; + MorphActor = "int MorphActor(int tid, [str playerclass, [str monsterclass, [int duration, [int style, [str morphflash, [str unmorphflash]]]]]])"; + NamedRequestScriptPuke = "int NamedRequestScriptPuke(str script[, int arg0[, int arg1[, int arg2[, int arg3]]]])"; + NamedScriptWait = "void NamedScriptWait(str script)"; NoiseAlert = "NoiseAlert(target_tid, emiter_tid)"; - Open = "Script expression Open"; Pillar_Build = "Pillar_Build(tag, speed, height)"; - Pillar_BuildAndCrush = "Pillar_BuildAndCrush(tag, speed, height, crush)"; + Pillar_BuildAndCrush = "Pillar_BuildAndCrush(tag, speed, height, crush, crushmode)"; Pillar_Open = "Pillar_Open(tag, speed, fdist, cdist)"; - Plane_Align = "Plane_Align(floor, ceiling)"; Plat_DownByValue = "Plat_DownByValue(tag, speed, delay, height)"; Plat_DownWaitUpStay = "Plat_DownWaitUpStay(tag, speed, delay)"; - Plat_DownWaitUpStayLip = "Plat_DownWaitUpStayLip(tag, speed, delay, lip)"; + Plat_DownWaitUpStayLip = "Plat_DownWaitUpStayLip(tag, speed, delay, lip, sound)"; Plat_PerpetualRaise = "Plat_PerpetualRaise(tag, speed, delay)"; Plat_PerpetualRaiseLip = "Plat_PerpetualRaiseLip(tag, speed, delay, lip)"; - Plat_RaiseAndStayTx0 = "Plat_RaiseAndStayTx0(tag, speed)"; + Plat_RaiseAndStayTx0 = "Plat_RaiseAndStayTx0(tag, speed, lockout)"; Plat_Stop = "Plat_Stop(tag)"; Plat_ToggleCeiling = "Plat_ToggleCeiling(tag)"; Plat_UpByValue = "Plat_UpByValue(tag, speed, delay, height)"; Plat_UpByValueStayTx = "Plat_UpByValueStayTx(tag, speed, height)"; Plat_UpNearestWaitDownStay = "Plat_UpNearestWaitDownStay(tag, speed, delay)"; Plat_UpWaitDownStay = "Plat_UpWaitDownStay(tag, speed, delay)"; - Player_GiveItem = "Player_GiveItem(item, message)"; - Player_RemoveItem = "Player_RemoveItem(item, message)"; - Player_SetTeam = "Player_SetTeam(team)"; - PlayerArmorPoints = "PlayerArmorPoints()"; - PlayerBlueSkull = "PlayerBlueSkull()"; - PlayerClass = "PlayerClass(player_number)"; - PlayerCount = "PlayerCount()"; - PlayerFrags = "PlayerFrags()"; - PlayerHealth = "PlayerHealth()"; - PlayerInGame = "PlayerInGame(player_number)"; - PlayerIsBot = "PlayerIsBot(player_number)"; - PlayerNumber = "PlayerNumber()"; - PlayerOnTeam = "PlayerOnTeam()"; - PlayerRedSkull = "PlayerRedSkull()"; - PlayerTeam = "PlayerTeam()"; - PlayerYellowSkull = "PlayerYellowSkull()"; - PlayMovie = "PlayMovie(moviename)"; + PlayActorSound = "void PlayActorSound(int tid, int sound, int channel, fixed volume, bool looping, fixed attenuation)"; + PlayerArmorpoints = "int PlayerArmorpoints()"; + PlayerClass = "int PlayerClass(int playernumber)"; + PlayerCount = "int PlayerCount()\nReturns the number of players currently in the game"; + PlayerFrags = "int PlayerFrags()"; + PlayerHealth = "int PlayerHealth()"; + PlayerIsLoggedIn = "int PlayerIsLoggedIn(int playernumber)"; + PlayerInGame = "bool PlayerInGame(int playernumber)\nReturns true if the player [0..7] is in the game"; + PlayerIsBot = "bool PlayerIsBot(int playernumber)\nReturns TRUE if the player [0..7] is a bot and FALSE if not"; + PlayerIsSpectator = "int PlayerIsSpectator(int player)"; + PlayerNumber = "int PlayerNumber()\nReturns the player number for the player who activated the script, starting at 0.\nFor scripts that were not activated by a player, PlayerNumber will return -1."; + PlayerTeam = "int PlayerTeam()"; + PlaySound = "void PlaySound(int tid, str sound[, int channel = CHAN_BODY[, fixed volume = 1.0[, bool looping = false[, fixed attenuation = ATTN_NORM]]]])"; Polyobj_DoorSlide = "Polyobj_DoorSlide(po, speed, angle, dist, delay)"; Polyobj_DoorSwing = "Polyobj_DoorSwing(po, speed, angle, delay)"; Polyobj_Move = "Polyobj_Move(po, speed, angle, dist)"; Polyobj_MoveTimes8 = "Polyobj_MoveTimes8(po, speed, angle, dist)"; + Polyobj_MoveTo = "Polyobj_MoveTo(po, speed, pos_x, pos_y)"; + Polyobj_MoveToSpot = "Polyobj_MoveToSpot(po, speed, target)"; Polyobj_OR_Move = "Polyobj_OR_Move(po, speed, angle, distance)"; Polyobj_OR_MoveTimes8 = "Polyobj_OR_MoveTimes8(po, speed, angle, distance)"; - Polyobj_OR_RotateLeft = "Polyobj_OR_RotateLeft(po, speed)"; + Polyobj_OR_MoveTo = "Polyobj_OR_MoveTo(po, speed, pos_x, pos_y)"; + Polyobj_OR_MoveToSpot = "Polyobj_OR_MoveToSpot(po, speed, target)"; + Polyobj_OR_RotateLeft = "Polyobj_OR_RotateLeft(po, speed, angle)"; Polyobj_OR_RotateRight = "Polyobj_OR_RotateRight(po, speed, angle)"; Polyobj_RotateLeft = "Polyobj_RotateLeft(po, speed, angle)"; Polyobj_RotateRight = "Polyobj_RotateRight(po, speed, angle)"; - PolyWait = "PolyWait(po)"; - Print = "Print(type:expression)"; - PrintBold = "PrintBold(type:expression)"; - PointPush_SetForce = "PointPush_SetForce(tag, tid, amount, useline)"; + Polyobj_Stop = "Polyobj_Stop(po)"; + PolyWait = "void PolyWait(int polyid)"; + Print = "void Print(type:expression)\nPrint will print something to the screen.\nPrint will only display for the activator of the script\nFor printing to all players, use PrintBold."; + PrintBold = "void PrintBold(type:expression)\nThis is exactly the same as Print, except all players will see the printed text\non the screen instead of just the activator of the script."; Radius_Quake = "Radius_Quake(intensity, duration, damrad, tremrad, tid)"; - Random = "Random(low, high)"; - ReplaceTextures = "ReplaceTextures(oldtexture, newtexture, flags)"; - RedTeamCount = "RedTeamCount()"; - RedTeamScore = "RedTeamScore()"; - Respawn = "Script expression Respawn"; - Restart = "Restart"; - Script = "Script expression (Void)"; - ScriptWait = "ScriptWait(scriptid)"; - Scroll_Ceiling = "Scroll_Ceiling(tag, scrollbits, 0, xmove, ymove)"; - Scroll_Floor = "Scroll_Floor(tag, scrollbits, method xmove, ymove)"; + Radius_Quake2 = "void Radius_Quake2(int tid, int intensity, int duration, int damrad, int tremrad, str sound)"; + Random = "int Random(int min, int max)"; + ReplaceTextures = "void ReplaceTextures(str oldtexturename, str newtexturename[, int flags])\nReplaces all occurences of oldtexturename with newtexturename.\nNOT_ flags can be used."; + RequestScriptPuke = "int RequestScriptPuke(int script[, int arg0[, int arg1[, int arg2[, int arg3]]]])"; + ResetMap = "int ResetMap()"; + ScriptWait = "void ScriptWait(int script)"; + Scroll_Ceiling = "Scroll_Ceiling(tag, x-move, y-move, unused)"; + Scroll_Floor = "Scroll_Floor(tag, x-move, y-move, type)"; Scroll_Texture_Both = "Scroll_Texture_Both(lineid, left, right, down, up)"; - Scroll_Texture_Model = "Scroll_Texture_Model(lineid, scrollbits)"; - Scroll_Texture_Offsets = "Scroll_Texture_Offsets"; Scroll_Wall = "Scroll_Wall(lineid, x, y, side, flags)"; + Sector_ChangeFlags = "Sector_ChangeFlags(tag, setflags, clearflags)"; Sector_ChangeSound = "Sector_ChangeSound(tag, newsequence)"; Sector_SetCeilingPanning = "Sector_SetCeilingPanning(tag, u-int, u-frac, v-int, v-frac)"; Sector_SetCeilingScale = "Sector_SetCeilingScale(tag, u-int, u-frac, v-int, v-frac)"; - Sector_SetColor = "Sector_SetColor(tag, r, g, b)"; + Sector_SetCeilingScale2 = "Sector_SetCeilingScale2(tag, u-fixed, v-fixed)"; + Sector_SetColor = "Sector_SetColor(tag, red, green, blue, desaturation)"; + Sector_SetCurrent = "Sector_SetCurrent(tag, amount, angle, useline)"; Sector_SetDamage = "Sector_SetDamage(tag, amount, mod)"; - Sector_SetFade = "Sector_SetFade(tag, r, g, b)"; + Sector_SetFade = "Sector_SetFade(tag, red, green, blue)"; Sector_SetFloorPanning = "Sector_SetFloorPanning(tag, u-int, u-frac, v-int, v-frac)"; Sector_SetFloorScale = "Sector_SetFloorScale(tag, u-int, u-frac, v-int, v-frac)"; + Sector_SetFloorScale2 = "Sector_SetFloorScale2(tag, u-fixed, v-fixed)"; Sector_SetFriction = "Sector_SetFriction(tag, amount)"; Sector_SetGravity = "Sector_SetGravity(tag, ipart, fpart)"; Sector_SetLink = "Sector_SetLink(controltag, tag, surface, movetype)"; Sector_SetPlaneReflection = "Sector_SetPlaneReflection(tag, floor, ceiling)"; - Sector_SetRotation = "Sector_SetRotation(tag, floor-angle, ceiling-angle)"; - SectorDamage = "SectorDamage(tag, amount, type, protection-item, flags)"; - SectorSound = "SectorSound(name, volume)"; + Sector_SetRotation = "Sector_SetRotation(tag, floorangle, ceilingangle)"; + Sector_SetTranslucent = "Sector_SetTranslucent(tag, plane, amount, type)"; + Sector_SetWind = "Sector_SetWind(tag, amount, angle, useline)"; + SectorDamage = "void SectorDamage(int tag, int amount, str type, str protection_item, int flags)\nDoes the damage only when the function is called,\nand damages everything in the tagged sector.\nUses DAMAGE_ flags."; + SectorSound = "void SectorSound(str sound, int volume)"; SendToCommunicator = "SendToCommunicator(voc_id, front_only, indentify, nolog)"; - SetActorAngle = "SetActorAngle(tid, angle)"; - SetAirControl = "SetAirControl(amount)"; - SetActorPitch = "SetActorPitch(tid, angle)"; - SetActorPosition = "SetActorPosition(tid, x, y, z, fog)"; - SetActorProperty = "SetActorProperty(tid, property, value)"; - SetActorState = "SetActorState(tid, state, exact)"; - SetActorVelocity = "SetActorVelocity(tid, velx, vely, velz, add, setbob)"; - SetAirSupply = "SetAirSupply(playernumber, tics)"; - SetCameraToTexture = "SetCameraToTexture(tag, texture, fov)"; - SetCeilingTrigger = "SetCeilingTrigger(tag, height, special, arg1, arg2, arg3, arg4, arg5)"; + SetActivator = "int SetActivator(int tid[, int pointer_selector])\nThis changes the activator of the script to the first actor found with the specified tid.\ntid: TID of the new activator.\npointer_selector: the pointer of the TID to set as the new activator (use AAPTR_ flags)."; + SetActivatorToTarget = "bool SetActivatorToTarget(int tid)\nThis changes the activator of the script to the current target\nof the first actor found with the specified tid.\nUsing a tid of 0 uses the current activator's target."; + SetActorAngle = "void SetActorAngle(int tid, fixed angle)\nSets the actor's angle.\nangle: a fixed point angle in the range of 0.0 to 1.0 (N = 0.25, W = 0.5, S = 0.75, E = 1.0)."; + SetActorPitch = "void SetActorPitch(int tid, int pitch)\nSets the actor's Pitch.\npitch: a fixed point angle in the range of 0.0 to 1.0."; + SetActorPosition = "bool SetActorPosition(int tid, fixed x, fixed y, fixed z, bool fog)\nThis function sets the x, y, and z coordinates of the specified actor, with or without teleport fog.\nReturns TRUE if the actor position was changed successfully."; + SetActorProperty = "void SetActorProperty(int tid, int property, [int|float|str] value)\nproperty: one of the APROP_ properties."; + SetActorRoll = "void SetActorRoll(int tid, fixed angle)"; + SetActorState = "int SetActorState(int tid, str statename[, bool exact])\nForces the actor(s) with the matching tid into the specified state, as defined in Decorate.\nIf tid is 0, the activator is affected.\nThe exact parameter specifies whether or not partial state name matches are accepted."; + SetActorVelocity = "bool SetActorVelocity(int tid, fixed velx, fixed vely, fixed velz, bool add, bool setbob)\nChanges actor velocity.\ntid: TID of things to affect. If 0, the activator is used.\nvelx, vely, velz: The desired velocity for the affected things.\nadd: If true, each affected actor's velocity is modified by the velx, vely\nand velz parameters, rather than replaced by them.\nsetbob: If true, the speed adjustment influences the bobbing of any concerned player actor."; + SetAirControl = "void SetAirControl(fixed amount)\nSets how well the player can move while in the air.\nThe default amount is 0.00390625."; + SetAirSupply = "bool SetAirSupply(int playernum, int tics)\nSets the amount of tics remaining in a player's air supply."; + SetAmmoCapacity = "void SetAmmoCapacity(str typename, int maxamount)\nSets the maximum amount of a type of ammo the player can carry."; + SetCameraToTexture = "void SetCameraToTexture(int cameratid, str texturename, int fov)\nBinds the named texture to the specified camera\n(which does not have to be an actual camera thing).\nThe texture used must be defined as a “cameratexture” in the ANIMDEFS lump."; + SetCeilingTrigger = "void SetCeilingTrigger(int tag, int height, int special[, int arg1[, int arg2[, int arg3[, int arg4[, int arg5]]]]])\nWhen the ceiling specified by tag moves the specified height,\nspecial(arg1, arg2, arg3, arg4, arg5) will be activated."; + SetCVar = "bool SetCVar(str cvar, int value)\nSets the value of a particular console variable.\nOnly mod-defined console variables through CVARINFO can be changed by using this function.\nReturns FALSE if cvar is invalid, or it is not writable."; + SetCVarString = "bool SetCVarString(str cvar, str value)\nSets the value of a particular console variable.\nOnly mod-defined console variables through CVARINFO can be changed by using this function.\nReturns FALSE if cvar is invalid, or it is not writable."; + SetDBEntry = "int SetDBEntry(table, variable, value)"; + SetDBEntryString = "void SetDBEntryString(str namespace, str key, str value)"; SetFloorTrigger = "SetFloorTrigger(tag, height, special, arg1, arg2, arg3, arg4, arg5)"; - SetFont = "SetFont(fontname)"; - SetGravity = "SetGravity(amount)"; - SetHudSize = "SetHudSize(width, height, statusbar)"; - SetLineBlocking = "SetLineBlocking(line, blocking)"; - SetLineMonsterBlocking = "SetLineMonsterBlocking(line, blocking)"; - SetLineSpecial = "SetLineSpecial(line, special, arg1, arg2, arg3, arg4, arg5)"; - SetLineTexture = "SetLineTexture(line, side, position, texture)"; - SetMarineSprite = "SetMarineSprite(tid, actorclass)"; - SetMarineWeapon = "SetMarineWeapon(tid, weapon)"; - SetMugShotState = "SetMugShotState(state)"; - SetMusic = "SetMusic(song, pattern, transition)"; + SetFont = "void SetFont(str fontlump)\nSets the current font (only within the script) to fontlump"; + SetGlobalFogParameter = "SetGlobalFogParameter(property, value)"; + SetGravity = "void SetGravity(fixed amount)\nThis function sets the global gravity of an entire level.\nDefault is 800.0"; + SetHUDClipRect = "void SetHUDClipRect(int x, int y, int width, int height[, int wrapwidth = 0])\nSets the clipping rectangle for future HUD messages."; + SetHudSize = "void SetHudSize(int width, int height, bool statusbar)\nCauses text messages to be stretched or shrunk to match the size\nthey would appear if the user's resolution was width by height."; + SetHUDWrapWidth = "void SetHudWrapWidth(int wrapwidth)\nSets the wrapping width for future HUD messages without altering the clipping rectangle.\nIf you set the wrapping width to 0, messages will wrap\nto the full width of the HUD, as normal."; + SetLineActivation = "void SetLineActivation(int lineid, int activation)\nSets the line activation flags of the line with the specified id.\nlineid: The id of the line of which to set the activation flags\nactivation: SPAC_ flags to set. Multiple flags can be set by using the pipe character | between the constant names."; + SetLineBlocking = "void SetLineBlocking(int lineid, int blocking)\nDEPRECATED!\nUse Line_SetBlocking instead!"; + SetLineMonsterBlocking = "void SetLineMonsterBlocking(int lineid, int setting)\nDEPRECATED!\nUse Line_SetBlocking instead!"; + SetLineSpecial = "void SetLineSpecial(int lineid, int special[, int arg0[, int arg1[, int arg2[, int arg3[, int arg4]]]]])\nSetLineSpecial will change the special on all lines with the line id number specified."; + SetLineTexture = "void SetLineTexture(int lineid, int line_side, int sidedef_texture, str texturename)\nSetLineTexture will change the specified texture on all lines with the line id number specified\nline_side: SIDE_ flags can be used.\nsidedef_texture: TEXTURE_ flags can be used.\ntexturename: the texture that will be set on the line. Use '-' to remove a texture."; + SetMarineSprite = "void SetMarineSprite(int tid, str actorclass)\nChanges a Scripted Marine's sprite to match the sprite\nused in the specified actor's spawn state."; + SetMarineWeapon = "void SetMarineWeapon(int tid, int weapon)\nSets a Scripted Marine's weapon on the fly.\nweapon: one of MARINEWEAPON_ flags"; + SetMugShotState = "void SetMugShotState(str state)\nSets the state of the mug shot in SBARINFO status bars.\nThe state you set will only be interrupted by damage or if the player\npicks up a weapon, provided the mugshot supports it."; + SetMusic = "void SetMusic(str song[, int order[, int unused]])"; + SetPlayerLivesLeft = "int SetPlayerLivesLeft(int player, int amount)"; SetPlayerProperty = "SetPlayerProperty(who, set, which)"; - SetResultValue = "SetResultValue(value)"; - SetSkyScrollSpeed = "SetSkyScrollSpeed(skynumber, speed)"; - SetThingSpecial = "SetThingSpecial(tid, special, arg1, arg2, arg3, arg4, arg5)"; - SetWeapon = "SetWeapon(weaponname)"; - sin = "sin(angle)"; - SinglePlayer = "SinglePlayer()"; - SoundSequence = "SoundSequence(name)"; - SoundSequenceOnActor = "SoundSequenceOnActor(tid, sndseq)"; - SoundSequenceOnSector = "SoundSequenceOnSector(tag, sndseq, location)"; - SoundSequenceOnPolyObj = "SoundSequenceOnPolyObj(tag, sndseq)"; - Spawn = "Spawn(type, x, y, z, thingid, angle)"; - SpawnProjectile = "SpawnProjectile(tid, type, angle, speed, vspeed, gravity, newtid)"; - SpawnSpot = "SpawnSpot(type, spotid, thingid, angle)"; - SpawnSpotFacing = "SpawnSpotFacing(type, spotid, thingid)"; + SetPointer = "bool SetPointer(int assign_slot, int tid[, int pointer_selector[, int flags]])\nSet the value of one of the caller's stored pointers."; + SetResultValue = "void SetResultValue(int value)"; + SetSkyScrollSpeed = "void SetSkyScrollSpeed(int sky, fixed skyspeed)\nChanges the scrolling speed of a sky.\nThis is useful in conjunction with ChangeSky.\nsky: either 1 or 2.\nskyspeed: the desired scrolling speed."; + SetThingSpecial = "void SetThingSpecial(int tid, int special[, int arg0[, int arg1[, int arg2[, int arg3[, int arg4]]]]])\nSets the special for any things with the same TID.\nThis is similar to Thing_SetSpecial, except it can only be used from ACS,\nand it can set all of a thing's special arguments.\nIf tid is 0, then the activator is used."; + SetUserArray = "void SetUserArray(int tid, str name, int pos, int value)\nSets one of the affected actor's user array-bound variables."; + SetUserCVar = "bool SetUserCVar(int playernumber, str cvar, int value)\nSets the console variable of a particular player.\nOnly mod-defined console variables through CVARINFO can be changed by using this function.\nReturns FALSE if cvar is invalid, it is not writable, or the player doesn't exist."; + SetUserCVarString = "bool SetUserCVarString(int playernumber, str cvar, str value)\nSets the console variable of a particular player.\nOnly mod-defined console variables through CVARINFO can be changed by using this function.\nReturns FALSE if cvar is invalid, it is not writable, or the player doesn't exist."; + SetUserVariable = "void SetUserVariable(int tid, str name, int value)\nSets one of the affected actor's user variables."; + SetWeapon = "bool SetWeapon(str weaponname)\nSets the player's current weapon to weaponname.\nReturns TRUE if the weapon was set successfully, and FALSE if not."; + Sin = "fixed Sin(int angle)"; + SortDBEntries = "int SortDBEntries(str namespace, int limit, int offset, bool order)"; + SoundSequence = "void SoundSequence(str sndseq)\nPlays a sound sequence defined in SNDSEQ lump."; + SoundSequenceOnActor = "void SoundSequenceOnActor(int tid, str sndseq)\nPlays a sound sequence defined in SNDSEQ lump."; + SoundSequenceOnPolyObj = "void SoundSequenceOnPolyobj(int polynum, str sndseq)\nPlays a sound sequence defined in SNDSEQ lump."; + SoundSequenceOnSector = "void SoundSequenceOnSector(int tag, str sndseq, int location)\nPlays a sound sequence defined in SNDSEQ lump."; + SoundVolume = "void SoundVolume(int tid, int channel, fixed volume)\nChanges the volume of the currently playing sound by the actor(s) with the specified tid.\nIf tid is 0, the sound volume change is done to the sound being played by the activator of the script."; + Spawn = "int Spawn(str classname, fixed x, fixed y, fixed z[, int tid[, int angle]])\nSpawns an actor at the given X, Y and Z coordinates.\nOptionally a TID and a byte angle can be specified."; + SpawnForced = "int SpawnForced(str classname, fixed x, fixed y, fixed z[, int tid[, int angle]])\nForces the actor to spawn, even in conditions where the spawning would normally fail.\nThe return value is the number of things spawned."; + SpawnDecal = "int SpawnDecal(int tid, str decalname, int flags[, fixed angle = 0.0[, fixed zoffset = 0.0[, fixed distance = 64.0]]])\nCreates a decal on a wall by tracing a line from the actor with the\nspecified tid until hitting said wall, on which the decal is then created.\nIf tid is 0, the tracing is done from the activator of the script.\ndecalname: The name of the decal to create, as defined in DECALDEF.\nflags: use SDF_ flags\nThe return value of the function is the number of decals spawned."; + SpawnProjectile = "void SpawnProjectile(int tid, str type, int angle, int speed, int vspeed, int gravity, int newtid)"; + SpawnSpot = "int SpawnSpot(str classname, int spottid[, int tid[, int angle]])\nRequires a MapSpot at the location where you want the Actor to spawn.\nThe return value is the number of things spawned."; + SpawnSpotFacing = "int SpawnSpotFacing(str classname, int spottid[, int tid])\nRequires a MapSpot at the location where you want the Actor to spawn.\nThe thing will assume the angle of the mapspot it is spawned to.\nThe return value is the number of things spawned."; + SpawnSpotFacingForced = "int SpawnSpotFacingForced(str classname, int spottid[, int tid])\nRequires a MapSpot at the location where you want the Actor to spawn.\nForces the actor to spawn, even in conditions where the spawning would normally fail.\nThe thing will assume the angle of the mapspot it is spawned to.\nThe return value is the number of things spawned."; + SpawnSpotForced = "int SpawnSpotForced(str classname, int spottid[, int tid[, int angle]])\nRequires a MapSpot at the location where you want the Actor to spawn.\nForces the actor to spawn, even in conditions where the spawning would normally fail.\nThe return value is the number of things spawned."; Special = "Special"; + Sqrt = "int Sqrt(int number)"; Stairs_BuildDown = "Stairs_BuildDown(tag, speed, height, delay, reset)"; Stairs_BuildDownSync = "Stairs_BuildDownSync(tag, speed, height, reset)"; Stairs_BuildUp = "Stairs_BuildUp(tag, speed, height, delay, reset)"; Stairs_BuildUpDoom = "Stairs_BuildUpDoom(tag, speed, height, delay, reset)"; Stairs_BuildUpSync = "Stairs_BuildUpSync(tag, speed, height, reset)"; - StartConversation = "StartConversation(tid, facing)"; - Str = "Str expression"; - strlen = "strlen(string)"; - Suspend = "Suspend"; - Switch = "Switch(expression)"; - TagWait = "TagWait(tag)"; - TakeActorInventory = "TakeActorInventory(tid, type, amount)"; - TakeInventory = "TakeInventory(type, amount)"; - Team_GivePoints = "Team_GivePoints(team, amount, announce)"; - Team_Score = "Team_Score(amount, nogrin)"; + StartConversation = "StartConversation(talker_tid, facetalker)"; + StopSound = "void StopSound(int tid, int channel)\nStops the sound currently playing on the specified channel for the actor with matching tid"; + StrCmp = "int StrCmp(str string1, str string2[, int maxcomparenum])\nCompares the two strings passed in arguments string1 and string2 character by character.\nIf maxcomparenum is specified, it only compares up to maxcomparenum characters of each string."; + StrCpy = "bool StrCpy(a:destination, str source[, int source_index])\nCopy a source string to a destination array as a series of characters.\nOptionally, the copy can start from a given index in the source string.\nReturns TRUE if the entire string (or substring) was successfully copied to the array;\nFALSE if the copy ran out of room or if a negative source_index was given."; + Strftime = "str Strftime(int timestamp, str format[, bool utc])"; + StrIcmp = "int StrCmp(str string1, str string2[, int maxcomparenum])\nStrIcmp is case-insensitive version of StrCmp"; + StrLeft = "str StrLeft(str string, int length)\nCreates a new string containing the length first characters of string.\nIf string does not exist, an empty string is returned.\nIf string is shorter than length characters, the entire string is returned."; + StrLen = "int StrLen(str string)"; + StrMid = "str StrMid(str string, int start, int length)\nCreates a new string containing the length characters of string starting from the one at position start.\nIf string does not exist or is shorter than start characters, an empty string is returned. \nIf string is shorter than start + length characters, the entire substring beginning at start is returned."; + StrParam = "int StrParam(type:expression)\nStrParam will create a new string formatted based upon the same method for Print or Log.\nThe return value is the string table index of the new string."; + StrRight = "str StrRight(str string, int length)\nCreates a new string containing the length last characters of string.\nIf string does not exist, an empty string is returned.\nIf string is shorter than length characters, the entire string is returned."; + SystemTime = "int SystemTime()"; + TagWait = "void TagWait(int tag)"; + TakeActorInventory = "void TakeActorInventory(int tid, str inventory_item, int amount)\nThis function will take the amount of items from the specified actor.\nTakeActorInventory can remove items that are flagged as undroppable."; + TakeInventory = "void TakeInventory(str inventory_item, int amount)\nThis function will take the number of items specified from the activator.\nTakeInventory can remove items that are flagged as undroppable."; Teleport = "Teleport(tid, tag, nosourcefog)"; Teleport_EndGame = "Teleport_EndGame()"; - Teleport_Line = "Teleport_Line(thisid, destid, flip)"; - Teleport_NewMap = "Teleport_NewMap(map, pos)"; - Teleport_NoFog = "Teleport_NoFog(tid)"; - Teleport_NoStop = "Teleport_NoStop(tid, sector, nofog)"; + Teleport_NewMap = "Teleport_NewMap(map, pos, face)"; + Teleport_NoFog = "Teleport_NoFog(tid, useangle, tag)"; + Teleport_NoStop = "Teleport_NoStop(tid, tag, nofog)"; Teleport_ZombieChanger = "Teleport_ZombieChanger(tid, tag)"; TeleportGroup = "TeleportGroup(groupid, sourceid, destinationid, movesource, fog)"; TeleportInSector = "TeleportInSector(tag, sourceid, destinationid, fog, groupid)"; TeleportOther = "TeleportOther(tid, destinationid, fog)"; - Terminate = "Terminate"; Thing_Activate = "Thing_Activate(tid)"; Thing_ChangeTID = "Thing_ChangeTID(oldtid, newtid)"; Thing_Damage = "Thing_Damage(tid, amount, mod)"; - Thing_Damage2 = "Thing_Damage2(tid, amount, type)"; + Thing_Damage2 = "int Thing_Damage2(int tid, int amount, str type)\nDamages the specified actor.\nDamage type is specified by name."; Thing_Deactivate = "Thing_Deactivate(tid)"; - Thing_Destroy = "Thing_Destroy(tid, extreme)"; + Thing_Destroy = "Thing_Destroy(tid, extreme, tag)"; Thing_Hate = "Thing_Hate(hater, hatee, type)"; Thing_Move = "Thing_Move(tid, destid, nofog)"; Thing_Projectile = "Thing_Projectile(tid, type, angle, speed, vspeed)"; - Thing_Projectile2 = "Thing_Projectile2(tid, type, angle, speed, vspeed, gravity, newtid)"; + Thing_Projectile2 = "void Thing_Projectile2(int tid, int type, int angle, int speed, int vspeed, int gravity, int newtid)"; Thing_ProjectileAimed = "Thing_ProjectileAimed(tid, type, speed, target, newtid)"; Thing_ProjectileGravity = "Thing_ProjectileGravity(tid, type, angle, speed, vspeed)"; Thing_ProjectileIntercept = "Thing_ProjectileIntercept(tid, type, speed, target, newtid)"; Thing_Raise = "Thing_Raise(tid)"; Thing_Remove = "Thing_Remove(tid)"; - Thing_SetFrame = "Thing_SetFrame(tid, frame)"; - Thing_SetGoal = "Thing_SetGoal(tid, goal, delay, ignore)"; + Thing_SetConversation = "Thing_SetConversation(tid, conversationid)"; + Thing_SetGoal = "Thing_SetGoal(tid, goal, delay, dontchasetarget)"; Thing_SetSpecial = "Thing_SetSpecial(tid, special, arg1, arg2, arg3)"; Thing_SetTranslation = "Thing_SetTranslation(tid, translation)"; Thing_Spawn = "Thing_Spawn(tid, type, angle, newtid)"; Thing_SpawnFacing = "Thing_SpawnFacing(tid, type, nofog, newtid)"; Thing_SpawnNoFog = "Thing_SpawnNoFog(tid, type, angle, newtid)"; Thing_Stop = "Thing_Stop(tid)"; - ThingCount = "ThingCount(type, id)"; - ThingCountName = "ThingCountName(type, tid)"; - ThingCountNameSector = "ThingCountNameSector(class, tid, tag)"; - ThingCountSector = "ThingCountSector(type, tid, tag)"; - ThingSound = "ThingSound(thingid, name, volume)"; - ThrustThing = "ThrustThing(angle, force, limit, tid)"; - ThrustThingZ = "ThrustThingZ(tid, speed, upordown, addorset)"; - Timer = "Timer()"; - Transfer_Heights = "Transfer_Heights(tag, flags)"; - Transfer_WallLight = "Transfer_WallLight(lineid, flags)"; - Transfer_CeilingLight = "Transfer_CeilingLight(tag)"; - Transfer_FloorLight = "Transfer_FloorLight(tag)"; - TranslucentLine = "TranslucentLine(lineid, amount, additive)"; - Unloading = "Script expression Unloading"; - UnmorphActor = "UnmorphActor(tid, force)"; - Until = "Until(expression)"; - UsePuzzleItem = "UsePuzzleItem(item, script)"; - UseActorInventory = "UseActorInventory(tid, item)"; - VectorAngle = "VectorAngle(x, y)"; - Void = "Void"; - While = "While(expression)"; - World = "World Int expression:identifier"; + ThingCount = "int ThingCount(int type, int tid)"; + ThingCountName = "int ThingCountName(str classname, int tid)"; + ThingCountNameSector = "int ThingCountNameSector(str classname, int tid, int tag)"; + ThingCountSector = "int ThingCountSector(int type, int tid, int tag)"; + ThingSound = "void ThingSound(int tid, str sound, int volume)\nPlays a sound at a thing.\nThis is a point sound, so anyone far away will not hear it as loudly"; + ThrustThing = "ThrustThing(angle, force, nolimit, tid)"; + ThrustThingZ = "ThrustThingZ(tid, speed, up_or_down, add_or_set)"; + Timer = "int Timer()"; + TranslucentLine = "TranslucentLine(lineid, amount, additive, moreflags)"; + UniqueTID = "int UniqueTID([int tid[, int limit]])"; + UnMorphActor = "int UnMorphActor(int tid[, bool force])"; + UseActorInventory = "int UseActorInventory(int tid, str classname)\nForces the actor(s) with the specified tid to use an item from their inventory, if they have one.\nReturns TRUE if the item was used successfully."; + UseInventory = "int UseInventory(str classname)\nForces the activator to use the specified inventory item, if he has it.\nReturns TRUE if the item was used successfully."; + UsePuzzleItem = "UsePuzzleItem(item, script, arg1, arg2, arg3)"; + VectorAngle = "fixed VectorAngle(int x, int y)"; + VectorLength = "int VectorLength(int x, int y)"; + //WHITERETURN = "Script expression WhiteReturn"; +} + +properties +{ + bool; + break; + case; + CLIENTSIDE; + const; + continue; + DEATH; + default; + DISCONNECT; + do; + else; + ENTER; + EVENT; + for; + function; + global; + if; + int; + LIGHTNING; + NET; + OPEN; + PICKUP; + RESPAWN; + Restart; + return; + script; + str; + Suspend; + switch; + Terminate; + UNLOADING; + until; + void; + while; + world; } constants { - TRUE; - FALSE; - ON; - OFF; - YES; - NO; - CARRY; - SCROLL; - SCROLL_AND_CARRY; - ACTOR_NONE; - ACTOR_WORLD; - ACTOR_PLAYER; - ACTOR_BOT; - ACTOR_VOODOODOLL; - ACTOR_MONSTER; + AAPTR_DEFAULT; + AAPTR_FRIENDPLAYER; + AAPTR_MASTER; + AAPTR_NULL; + AAPTR_PLAYER_GETCONVERSATION; + AAPTR_PLAYER_GETTARGET; + AAPTR_PLAYER1; + AAPTR_PLAYER2; + AAPTR_PLAYER3; + AAPTR_PLAYER4; + AAPTR_PLAYER5; + AAPTR_PLAYER6; + AAPTR_PLAYER7; + AAPTR_PLAYER8; + AAPTR_TARGET; + AAPTR_TRACER; ACTOR_ALIVE; + ACTOR_BOT; ACTOR_DEAD; - ACTOR_MISSILE; ACTOR_GENERIC; + ACTOR_MISSILE; + ACTOR_MONSTER; + ACTOR_NONE; + ACTOR_PLAYER; + ACTOR_VOODOODOLL; + ACTOR_WORLD; + APROP_Accuracy; APROP_ActiveSound; APROP_Alpha; APROP_Ambush; - APROP_AttackSoun; + APROP_AttackSound; + APROP_AttackZOffset; APROP_ChaseGoal; APROP_Damage; + APROP_DamageFactor; APROP_DeathSound; + APROP_Dormant; APROP_Dropped; APROP_Friendly; APROP_Frightened; APROP_Gravity; APROP_Health; + APROP_Height; APROP_Invulnerable; APROP_JumpZ; + APROP_Mass; + APROP_MasterTID; + APROP_MeleeRange; + APROP_Nametag; APROP_Notarget; + APROP_Notrigger; APROP_PainSound; + APROP_Radius; + APROP_Reactiontime; APROP_RenderStyle; + APROP_ScaleX; + APROP_ScaleY; + APROP_Score; APROP_SeeSound; APROP_SpawnHealth; + APROP_Species; APROP_Speed; + APROP_Stamina; + APROP_StencilColor; + APROP_TargetTID; + APROP_TracerTID; + APROP_ViewHeight; + APROP_Waterlevel; + ATTN_IDLE; + ATTN_NONE; + ATTN_NORM; + ATTN_STATIC; BLOCK_CREATURES; BLOCK_EVERYTHING; BLOCK_NOTHING; BLOCK_PLAYERS; + BLOCK_RAILING; + BLOCKF_CREATURES; + BLOCKF_EVERYTHING; + BLOCKF_FLOATERS; + BLOCKF_HITSCAN; BLOCKF_MONSTERS; BLOCKF_PLAYERS; - BLOCKF_FLOATERS; BLOCKF_PROJECTILES; - BLOCKF_EVERYTHING; BLOCKF_RAILING; + BLOCKF_SIGHT; BLOCKF_USE; BT_ALTATTACK; BT_ATTACK; @@ -506,17 +640,36 @@ constants BT_USER3; BT_USER4; BT_ZOOM; + CARRY; + CHAN_AUTO; + CHAN_BODY; + CHAN_ITEM; + CHAN_LISTENERZ; + CHAN_MAYBE_LOCAL; + CHAN_NOPAUSE; + CHAN_UI; + CHAN_VOICE; + CHAN_WEAPON; + CHANGELEVEL_CHANGESKILL; + CHANGELEVEL_KEEPFACING; + CHANGELEVEL_NOINTERMISSION; + CHANGELEVEL_NOMONSTERS; + CHANGELEVEL_PRERAISEWEAPON; + CHANGELEVEL_RESETHEALTH; + CHANGELEVEL_RESETINVENTORY; CLASS_CLERIC; CLASS_FIGHTER; CLASS_MAGE; - CR_BLACK; + CR_BLACK; CR_BLUE; CR_BRICK; CR_BROWN; CR_CREAM; + CR_CYAN; CR_DARKBROWN; - CR_DARKGRAY; + CR_DARKGRAY; CR_DARKGREEN; + CR_DARKGREY; CR_DARKRED; CR_GOLD; CR_GRAY; @@ -531,33 +684,114 @@ constants CR_UNTRANSLATED; CR_WHITE; CR_YELLOW; + CSF_NOBLOCKALL; + CSF_NOFAKEFLOORS; DAMAGE_IN_AIR; DAMAGE_NONPLAYERS; DAMAGE_PLAYERS; DAMAGE_SUBCLASSES_PROTECT; + DB_ORDER_ASC; + DB_ORDER_DESC; + EV_Char; + EV_KeyDown; + EV_KeyRepeat; + EV_KeyUp; + EV_LButtonDblClick; + EV_LButtonDown; + EV_LButtonUp; + EV_MButtonDblClick; + EV_MButtonDown; + EV_MButtonUp; + EV_MouseMove; + EV_RButtonDblClick; + EV_RButtonDown; + EV_RButtonUp; + EV_WheelDown; + EV_WheelUp; + FALSE; + FHF_NORANDOMPUFFZ; + FOGP_DENSITY; + FOGP_OUTSIDEDENSITY; + FOGP_SKYFOG; + GAMESTATE_COUNTDOWN; + GAMESTATE_INPROGRESS; + GAMESTATE_INRESULTSEQUENCE; + GAMESTATE_UNSPECIFIED; + GAMESTATE_WAITFORPLAYERS; GAME_NET_COOPERATIVE; GAME_NET_DEATHMATCH; GAME_NET_TEAMGAME; GAME_SINGLE_PLAYER; + GAME_TITLE_MAP; + GK_ALERT; + GK_BACKSPACE; + GK_CESCAPE; + GK_DEL; + GK_DOWN; + GK_END; + GK_ESCAPE; + GK_F1; + GK_F10; + GK_F11; + GK_F12; + GK_F2; + GK_F3; + GK_F4; + GK_F5; + GK_F6; + GK_F7; + GK_F8; + GK_F9; + GK_FORMFEED; + GK_FREE1; + GK_FREE2; + GK_FREE3; + GK_HOME; + GK_LEFT; + GK_LINEFEED; + GK_PGDN; + GK_PGUP; + GK_RETURN; + GK_RIGHT; + GK_TAB; + GK_UP; + GK_VTAB; + GKM_ALT; + GKM_CTRL; + GKM_LBUTTON; + GKM_MBUTTON; + GKM_RBUTTON; + GKM_SHIFT; + HUDMSG_ADDBLEND; + HUDMSG_ALPHA; HUDMSG_COLORSTRING; HUDMSG_FADEINOUT; HUDMSG_FADEOUT; + HUDMSG_LAYER_OVERHUD; + HUDMSG_LAYER_OVERMAP; + HUDMSG_LAYER_UNDERHUD; HUDMSG_LOG; + HUDMSG_NOTWITH3DVIEW; + HUDMSG_NOTWITHFULLMAP; + HUDMSG_NOTWITHOVERLAYMAP; + HUDMSG_NOWRAP; HUDMSG_PLAIN; HUDMSG_TYPEON; - IS_COUNTDOWN; - IS_FIRSTCOUNTDOWN; - IS_INPROGRESS; - IS_WAITINGFORPLAYERS; - IS_WAVECOMPLETE; INPUT_BUTTONS; INPUT_FORWARDMOVE; INPUT_OLDBUTTONS; INPUT_PITCH; - INPUT_ROW; + INPUT_ROLL; INPUT_SIDEMOVE; INPUT_UPMOVE; INPUT_YAW; + IS_BOSSFIGHT; + IS_COUNTDOWN; + IS_FIRSTCOUNTDOWN; + IS_INPROGRESS; + IS_MISSIONFAILED; + IS_WAITINGFORPLAYERS; + IS_WAVECOMPLETE; LEVELINFO_CLUSTERNUM; LEVELINFO_FOUND_ITEMS; LEVELINFO_FOUND_SECRETS; @@ -570,34 +804,35 @@ constants LEVELINFO_TOTAL_SECRETS; LINE_BACK; LINE_FRONT; - MARINEWEAPON_BerserkFis; + MARINEWEAPON_BerserkFist; MARINEWEAPON_BFG; MARINEWEAPON_Chaingun; MARINEWEAPON_Chainsaw; MARINEWEAPON_Dummy; MARINEWEAPON_Fist; MARINEWEAPON_Pistol; - MARINEWEAPON_PlasmaRifl; + MARINEWEAPON_PlasmaRifle; MARINEWEAPON_Railgun; - MARINEWEAPON_RocketLaunche; + MARINEWEAPON_RocketLauncher; MARINEWEAPON_Shotgun; - MARINEWEAPON_SuperShotgu; + MARINEWEAPON_SuperShotgun; MOD_BARREL; MOD_BFG_BOOM; MOD_BFG_SPLASH; - MOD_CHAINGUN; MOD_CHAINSAW; MOD_CRUSH; + MOD_DISINTEGRATE; + MOD_ELECTRIC; MOD_EXIT; MOD_FALLING; - MOD_FIST; MOD_HIT; + MOD_ICE; MOD_LAVA; - MOD_PISTOL; MOD_PLASMARIFLE; + MOD_POISON; MOD_R_SPLASH; + MOD_RAILGUN; MOD_ROCKET; - MOD_SHOTGUN; MOD_SLIME; MOD_SPLASH; MOD_SSHOTGUN; @@ -609,7 +844,7 @@ constants MODINPUT_FORWARDMOVE; MODINPUT_OLDBUTTONS; MODINPUT_PITCH; - MODINPUT_ROW; + MODINPUT_ROLL; MODINPUT_SIDEMOVE; MODINPUT_UPMOVE; MODINPUT_YAW; @@ -617,25 +852,72 @@ constants MOVIE_Played; MOVIE_Played_Aborted; MOVIE_Played_NoVideo; + MRF_ADDSTAMINA; + MRF_FAILNOLAUGH; + MRF_FAILNOTELEFRAG; + MRF_FULLHEALTH; + MRF_LOSEACTUALWEAPON; + MRF_NEWTIDBEHAVIOUR; + MRF_OLDEFFECTS; + MRF_UNDOBYCHAOSDEVICE; + MRF_UNDOBYDEATH; + MRF_UNDOBYDEATHFORCED; + MRF_UNDOBYDEATHSAVES; + MRF_UNDOBYTOMEOFPOWER; + MRF_WHENINVULNERABLE; + NO; + NO_CHANGE; NO_TEAM; NOT_BOTTOM; NOT_CEILING; NOT_FLOOR; NOT_MIDDLE; NOT_TOP; + OFF; + ON; PLAYERINFO_AIMDIST; PLAYERINFO_COLOR; + PLAYERINFO_DESIREDFOV; + PLAYERINFO_FOV; PLAYERINFO_GENDER; PLAYERINFO_MOVEBOB; PLAYERINFO_NEVERSWITCH; PLAYERINFO_PLAYERCLASS; PLAYERINFO_STILLBOB; PLAYERINFO_TEAM; + PRINTNAME_LEVEL; + PRINTNAME_LEVELNAME; + PRINTNAME_SKILL; + PROP_ALLMAP; + PROP_BUDDHA; + PROP_FLIGHT; PROP_FLY; PROP_FROZEN; + PROP_INFRARED; PROP_INSTANTWEAPONSWITCH; + PROP_INVISIBILITY; + PROP_INVULNERABILITY; PROP_NOTARGET; + PROP_RADIATIONSUIT; + PROP_SPEED; + PROP_STRENGTH; PROP_TOTALLYFROZEN; + PROP_WEAPONLEVEL2; + PTROP_NOSAFEGUARDS; + PTROP_UNSAFEMASTER; + PTROP_UNSAFETARGET; + SCROLL; + SCROLL_AND_CARRY; + SDF_ABSANGLE; + SDF_PERMANENT; + SECF_FLOORDROP; + SECF_NOFALLINGDAMAGE; + SECF_NORESPAWN; + SECF_SILENT; + SECSEQ_CEILING; + SECSEQ_FLOOR; + SECSEQ_FULLHEIGHT; + SECSEQ_INTERIOR; SIDE_BACK; SIDE_FRONT; SKILL_EASY; @@ -643,13 +925,40 @@ constants SKILL_NORMAL; SKILL_VERY_EASY; SKILL_VERY_HARD; + SOUND_Active; + SOUND_Attack; + SOUND_Bounce; + SOUND_CrushPain; + SOUND_Death; + SOUND_Howl; + SOUND_Pain; + SOUND_See; + SOUND_Use; + SOUND_WallBounce; + SPAC_AnyCross; + SPAC_Cross; + SPAC_Impact; + SPAC_MCross; + SPAC_MPush; + SPAC_MUse; + SPAC_None; + SPAC_PCross; + SPAC_Push; + SPAC_Use; + SPAC_UseBack; + SPAC_UseThrough; STYLE_Add; STYLE_Fuzzy; STYLE_None; STYLE_Normal; STYLE_OptFuzzy; + STYLE_Shaded; + STYLE_Shadow; STYLE_SoulTrans; + STYLE_Stencil; + STYLE_Subtract; STYLE_Translucent; + STYLE_TranslucentStencil; T_ABADDON; T_ABADDONSHOT; T_AMMOBOX; @@ -657,14 +966,12 @@ constants T_ANTIGRAVBELT; T_ARACHNOTRON; T_ARACHNOTRONPLASMA; - T_ARCHSTATUE; T_ARMORBONUS; T_ARROW; T_AXEKEY; T_BACKPACK; T_BARON; T_BARONBALL; - T_BARONSTATUE; T_BARREL; T_BATTERY; T_BEAST; @@ -689,7 +996,6 @@ constants T_BLUEKEYCARD; T_BLUESKULLKEY; T_BLUETELEGLITTER; - T_BOBBINGSKULLINFLAMES; T_BOUNCYMACEBALL; T_BRAINS; T_BRIDGE; @@ -717,17 +1023,14 @@ constants T_CROSSBOWMINIBLAST; T_CROSSBOWPOWERBLAST; T_CYBERDEMON; - T_CYBERDEMONSTATUE; T_DARKIMP; T_DARKIMPFIREBALL; T_DART; - T_DEADCYBERDEMON; T_DEATHBALL; T_DEMON; T_DEMON_MASH; T_DEMON1; T_DEMON2_MASH; - T_DEMONSTATUE; T_DIRT1; T_DIRT2; T_DIRT3; @@ -761,13 +1064,10 @@ constants T_FLESH_DRIP1; T_FLESH_DRIP2; T_GAUNTLETS; - T_GOTHICPILLAR; T_GREENARMOR; T_GREENKEY; T_GRENADE; T_GRENADELAUNCHER; - T_GREYPILLARHEART; - T_GREYSTALAGMITE; T_GUTS; T_HASTE; T_HEALTHBONUS; @@ -780,20 +1080,13 @@ constants T_HEFTYSKULLRODAMMO; T_HEFTYWANDAMMO; T_HELLKNIGHT; - T_HELLPILLAR; T_HIGHJUMP; - T_HISSY; T_HORNKEY; T_ICEGOLEM; T_ICESHARD; T_IMP; - T_IMPALINGSPIKE; - T_IMPALINGSPIKECGUN; - T_IMPALINGSPIKEZOMB; T_IMPFIREBALL; - T_IMPHEAD; T_IMPLEADER; - T_IMPSTATUE; T_INFRAGOGGLES; T_INFRATRACKER; T_INVISIBILITY; @@ -814,6 +1107,7 @@ constants T_ITEMHEALTHPOTION; T_ITEMINVISIBILITY; T_ITEMINVULNERABILITY; + T_ITEMPORK; T_ITEMREPULSION; T_ITEMSUMMON; T_ITEMTELEPORT; @@ -825,7 +1119,6 @@ constants T_KNIGHTAXE; T_KNIGHTBLOODAXE; T_KNIGHTGHOST; - T_LABORTORYPILLAR; T_LIGHTAMP; T_LOSTSOUL; T_MACE; @@ -839,14 +1132,12 @@ constants T_MANA3; T_MANCUBUS; T_MANCUBUSSHOT; - T_MASARMORBONUS; - T_MASSMOUTHSTATUE; + T_MAXARMORBONUS; T_MAXHEALTHBONUS; T_MEDKIT; T_MEGASPHERE; T_MESHARMOR; T_METALKEY; - T_MILITARYPILLAR; T_MINIGUN; T_MORPHBLAST; T_MUMMY; @@ -893,7 +1184,6 @@ constants T_REGENERATION; T_RESISTANCE; T_REVENANT; - T_REVENANTHAND; T_RIPPER; T_RIPPERBALL; T_ROCK1; @@ -904,8 +1194,6 @@ constants T_ROCKETBOX; T_ROCKETLAUNCHER; T_RUSTYKEY; - T_SAUSAGEHEAD; - T_SAUSAGESPITTER; T_SCRIPTEDMARINE; T_SERPENTFIREBALL; T_SERPENTKEY; @@ -913,7 +1201,6 @@ constants T_SHELLS; T_SHIELD1; T_SHIELD2; - T_SHORTGREYPILLAR; T_SHOTGUN; T_SHOTGUY; T_SILVERKEY; @@ -941,7 +1228,6 @@ constants T_STAINEDGLASS7; T_STAINEDGLASS8; T_STAINEDGLASS9; - T_STARBASEPILLAR; T_STEALTHARACHNOTRON; T_STEALTHBARON; T_STEALTHCACODEMON; @@ -957,8 +1243,6 @@ constants T_STIMPACK; T_STRENGTH; T_SUPERSHOTGUN; - T_TALLGOTHICPILLAR; - T_TALLGREYPILLAR; T_TEMPLARGEFLAME; T_TEMPSMALLFLAME; T_THRUSTSPIKEDOWN; @@ -993,7 +1277,38 @@ constants T_ZOMBIE; TEAM_BLUE; TEAM_RED; + TEXFLAG_ADDOFFSET; + TEXFLAG_BOTTOM; + TEXFLAG_MIDDLE; + TEXFLAG_TOP; TEXTURE_BOTTOM; TEXTURE_MIDDLE; TEXTURE_TOP; -} + TM_SECOND; + TM_MINUTE; + TM_HOUR; + TM_DAY; + TM_MONTH; + TM_YEAR; + TM_WEEKDAY; + TPROP_Assister; + TPROP_Carrier; + TPROP_DeathCount; + TPROP_FragCount; + TPROP_IsValid; + TPROP_LoserTheme; + TPROP_Name; + TPROP_NumLivePlayers; + TPROP_NumPlayers; + TPROP_PlayerStartNum; + TPROP_PointCount; + TPROP_ReturnTics; + TPROP_Score; + TPROP_Spread; + TPROP_TeamItem; + TPROP_TextColor; + TPROP_WinCount; + TPROP_WinnerTheme; + TRUE; + YES; +} \ No newline at end of file diff --git a/Source/Core/GZBuilder/Data/MapInfo.cs b/Source/Core/GZBuilder/Data/MapInfo.cs index 0b404c10db5b5def99e7f6c4a308f1c11d0cfb9a..a4cc03e403e145ea52709d8dae7d93386c495382 100644 --- a/Source/Core/GZBuilder/Data/MapInfo.cs +++ b/Source/Core/GZBuilder/Data/MapInfo.cs @@ -8,6 +8,21 @@ namespace CodeImp.DoomBuilder.GZBuilder.Data { public sealed class MapInfo { + #region ================== Enums + + public enum GZDoomLightMode + { + STANDARD, + BRIGHT, + DOOM, + DARK, + LEGACY, + SOFTWARE, + UNDEFINED + } + + #endregion + #region ================== Variables private bool isdefined; @@ -27,6 +42,7 @@ namespace CodeImp.DoomBuilder.GZBuilder.Data private bool evenlighting; private bool smoothlighting; + private GZDoomLightMode lightmode; private int vertwallshade; private int horizwallshade; @@ -51,6 +67,7 @@ namespace CodeImp.DoomBuilder.GZBuilder.Data public bool EvenLighting { get { return evenlighting; } internal set { evenlighting = value; isdefined = true; } } public bool SmoothLighting { get { return smoothlighting; } internal set { smoothlighting = value; isdefined = true; } } + public GZDoomLightMode LightMode { get { return lightmode; } internal set { lightmode = value; isdefined = true; } } public int VertWallShade { get { return vertwallshade; } internal set { vertwallshade = value; isdefined = true; } } public int HorizWallShade { get { return horizwallshade; } internal set { horizwallshade = value; isdefined = true; } } @@ -64,6 +81,7 @@ namespace CodeImp.DoomBuilder.GZBuilder.Data horizwallshade = -16; fogdensity = 255; outsidefogdensity = 255; + lightmode = GZDoomLightMode.UNDEFINED; } #endregion diff --git a/Source/Core/Rendering/Renderer.cs b/Source/Core/Rendering/Renderer.cs index 9a2f85bbf2310ce8cb7c6d1662e7ad6be9a98ffb..b2fd83c4cf16933a365be80cf73fa0ce2b2ddb73 100644 --- a/Source/Core/Rendering/Renderer.cs +++ b/Source/Core/Rendering/Renderer.cs @@ -17,6 +17,7 @@ #region ================== Namespaces using System; +using CodeImp.DoomBuilder.GZBuilder.Data; using CodeImp.DoomBuilder.Map; using CodeImp.DoomBuilder.Geometry; @@ -89,7 +90,16 @@ namespace CodeImp.DoomBuilder.Rendering public int CalculateBrightness(int level) { // Simulate doom light levels - if((level < 192) && General.Map.Config.DoomLightLevels) + bool usedoomlightlevels = General.Map.Config.DoomLightLevels; //mxd + + //mxd. Very limited LightMode support... + switch(General.Map.Data.MapInfo.LightMode) + { + case MapInfo.GZDoomLightMode.DOOM: usedoomlightlevels = true; break; + case MapInfo.GZDoomLightMode.STANDARD: usedoomlightlevels = false; break; + } + + if(level < 192 && usedoomlightlevels) level = (int)(192.0f - (192 - level) * 1.5f); byte blevel = (byte)General.Clamp(level, 0, 255); diff --git a/Source/Core/ZDoom/MapinfoParser.cs b/Source/Core/ZDoom/MapinfoParser.cs index 74a2a6736aa5792ca1ff0c81edf201f793287b2d..7d6ddb9903c535efac4fc53140abcae18eb1e1c0 100644 --- a/Source/Core/ZDoom/MapinfoParser.cs +++ b/Source/Core/ZDoom/MapinfoParser.cs @@ -464,6 +464,10 @@ namespace CodeImp.DoomBuilder.ZDoom mapinfo.SmoothLighting = true; break; + case "lightmode": + if(!ParseLightMode()) return false; + break; + case "}": return true; // Block end case "{": // Skip inner blocks @@ -652,16 +656,11 @@ namespace CodeImp.DoomBuilder.ZDoom private bool ParseFogDensity(string densitytype) { + SkipWhitespace(true); + if(!NextTokenIs("=")) return false; // New format only SkipWhitespace(true); string token = ReadToken(); - // New format - if(token == "=") - { - SkipWhitespace(true); - token = ReadToken(); - } - int val; if(!int.TryParse(token, NumberStyles.Integer, CultureInfo.InvariantCulture, out val)) { @@ -670,7 +669,6 @@ namespace CodeImp.DoomBuilder.ZDoom return false; } - val = Math.Max(0, val); if(densitytype == "fogdensity") mapinfo.FogDensity = val; else mapinfo.OutsideFogDensity = val; @@ -678,6 +676,28 @@ namespace CodeImp.DoomBuilder.ZDoom return true; } + private bool ParseLightMode() + { + SkipWhitespace(true); + if(!NextTokenIs("=")) return false; // New format only + SkipWhitespace(true); + string token = ReadToken(); + + int val; + if(!int.TryParse(token, NumberStyles.Integer, CultureInfo.InvariantCulture, out val)) + { + // Not numeric! + ReportError("Expected LightMode value, but got \"" + token + "\""); + return false; + } + + // Store + mapinfo.LightMode = (MapInfo.GZDoomLightMode)val; + + // All done here + return true; + } + #endregion }