mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-30 13:15:32 +00:00
Make the string argument to BetaComment optional
This commit is contained in:
parent
8a3889a81e
commit
ea0339d471
4 changed files with 20 additions and 14 deletions
|
@ -58,6 +58,8 @@ op 0x20029: PCRaiseRank, explicit reference
|
|||
op 0x2002a: PCLowerRank, explicit reference
|
||||
op 0x2002b: PCJoinFaction, explicit reference
|
||||
op 0x2002c: MenuTest
|
||||
op 0x2002d: BetaComment
|
||||
op 0x2002e: BetaComment, explicit reference
|
||||
opcodes 0x2002d-0x3ffff unused
|
||||
|
||||
Segment 4:
|
||||
|
@ -396,8 +398,8 @@ op 0x2000243: GetFactionReaction
|
|||
op 0x2000244: Activate, explicit
|
||||
op 0x2000245: ClearInfoActor
|
||||
op 0x2000246: ClearInfoActor, explicit
|
||||
op 0x2000247: BetaComment
|
||||
op 0x2000248: BetaComment, explicit
|
||||
op 0x2000247: (unused)
|
||||
op 0x2000248: (unused)
|
||||
op 0x2000249: OnMurder
|
||||
op 0x200024a: OnMurder, explicit
|
||||
op 0x200024b: ToggleMenus
|
||||
|
|
|
@ -1016,10 +1016,10 @@ namespace MWScript
|
|||
};
|
||||
|
||||
template <class R>
|
||||
class OpBetaComment : public Interpreter::Opcode0
|
||||
class OpBetaComment : public Interpreter::Opcode1
|
||||
{
|
||||
public:
|
||||
virtual void execute(Interpreter::Runtime &runtime)
|
||||
virtual void execute(Interpreter::Runtime &runtime, unsigned int arg0)
|
||||
{
|
||||
MWWorld::Ptr ptr = R()(runtime);
|
||||
|
||||
|
@ -1052,10 +1052,14 @@ namespace MWScript
|
|||
msg << "Script: " << ptr.getClass().getScript(ptr) << std::endl;
|
||||
}
|
||||
|
||||
std::string notes = runtime.getStringLiteral (runtime[0].mInteger);
|
||||
runtime.pop();
|
||||
if (!notes.empty())
|
||||
msg << "Notes: " << notes << std::endl;
|
||||
while (arg0 > 0)
|
||||
{
|
||||
std::string notes = runtime.getStringLiteral (runtime[0].mInteger);
|
||||
runtime.pop();
|
||||
if (!notes.empty())
|
||||
msg << "Notes: " << notes << std::endl;
|
||||
--arg0;
|
||||
}
|
||||
|
||||
runtime.getContext().report(msg.str());
|
||||
}
|
||||
|
@ -1221,8 +1225,8 @@ namespace MWScript
|
|||
interpreter.installSegment5 (Compiler::Misc::opcodeExplodeSpellExplicit, new OpExplodeSpell<ExplicitRef>);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeGetPcInJail, new OpGetPcInJail);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeGetPcTraveling, new OpGetPcTraveling);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeBetaComment, new OpBetaComment<ImplicitRef>);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeBetaCommentExplicit, new OpBetaComment<ExplicitRef>);
|
||||
interpreter.installSegment3 (Compiler::Misc::opcodeBetaComment, new OpBetaComment<ImplicitRef>);
|
||||
interpreter.installSegment3 (Compiler::Misc::opcodeBetaCommentExplicit, new OpBetaComment<ExplicitRef>);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeAddToLevCreature, new OpAddToLevCreature);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeRemoveFromLevCreature, new OpRemoveFromLevCreature);
|
||||
interpreter.installSegment5 (Compiler::Misc::opcodeAddToLevItem, new OpAddToLevItem);
|
||||
|
|
|
@ -308,8 +308,8 @@ namespace Compiler
|
|||
extensions.registerInstruction ("enablelevitation", "", opcodeEnableLevitation);
|
||||
extensions.registerFunction ("getpcinjail", 'l', "", opcodeGetPcInJail);
|
||||
extensions.registerFunction ("getpctraveling", 'l', "", opcodeGetPcTraveling);
|
||||
extensions.registerInstruction ("betacomment", "S", opcodeBetaComment, opcodeBetaCommentExplicit);
|
||||
extensions.registerInstruction ("bc", "S", opcodeBetaComment, opcodeBetaCommentExplicit);
|
||||
extensions.registerInstruction ("betacomment", "/S", opcodeBetaComment, opcodeBetaCommentExplicit);
|
||||
extensions.registerInstruction ("bc", "/S", opcodeBetaComment, opcodeBetaCommentExplicit);
|
||||
extensions.registerInstruction ("addtolevcreature", "ccl", opcodeAddToLevCreature);
|
||||
extensions.registerInstruction ("removefromlevcreature", "ccl", opcodeRemoveFromLevCreature);
|
||||
extensions.registerInstruction ("addtolevitem", "ccl", opcodeAddToLevItem);
|
||||
|
|
|
@ -228,8 +228,8 @@ namespace Compiler
|
|||
const int opcodeGetLockedExplicit = 0x20001c8;
|
||||
const int opcodeGetEffect = 0x20001cf;
|
||||
const int opcodeGetEffectExplicit = 0x20001d0;
|
||||
const int opcodeBetaComment = 0x2000247;
|
||||
const int opcodeBetaCommentExplicit = 0x2000248;
|
||||
const int opcodeBetaComment = 0x2002d;
|
||||
const int opcodeBetaCommentExplicit = 0x2002e;
|
||||
const int opcodeAddSoulGem = 0x20001f3;
|
||||
const int opcodeAddSoulGemExplicit = 0x20001f4;
|
||||
const int opcodeRemoveSoulGem = 0x20027;
|
||||
|
|
Loading…
Reference in a new issue