[#GetScriptOp]
= GetScriptOp
:mrdocs:

Reads the next opcode, and any pushed data, from a script&period;

== Synopsis

Declared in `&lt;script&sol;script&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
bool
GetScriptOp(
    xref:prevector-0c.adoc[CScriptBase::const&lowbar;iterator]& pc,
    xref:prevector-0c.adoc[CScriptBase::const&lowbar;iterator] end,
    xref:opcodetype.adoc[opcodetype]& opcodeRet,
    std::vector&lt;unsigned char&gt;* pvchRet);
----

== Return Value

true if an opcode was read successfully, false on malformed input&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *pc*
| In&sol;out iterator to the current position&semi; advanced past the opcode&period;
| *end*
| Iterator to the end of the script&period;
| *opcodeRet*
| Set to the opcode that was read&period;
| *pvchRet*
| If not null, set to the data pushed by the opcode&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
