Index

InsertAction

MMO.core.history · 1 symbol · generated 5 Oct 2026

class

InsertAction

history.js:149
class MMO.core.history.InsertAction extends MMO.core.history.Action
Namespace
MMO.core.history
Extends
Action

Index

constructor(target, api, doFn, undoFn, data)
execute() asyncCreate the entity, then run the local action with the id the server assigned it.
undo() asyncDelete the entity that was created, then roll the local action back.

Methods3

constructor(target, api, doFn, undoFn, data)

history.js:150
constructor(target, api, doFn, undoFn, data)
target
api
doFn
undoFn
data

execute()

asynchistory.js:161

Create the entity, then run the local action with the id the server assigned it.

async execute()
returnsPromise<boolean>false when the action had already run
throwsserver's error when it refused the insert

undo()

asynchistory.js:178

Delete the entity that was created, then roll the local action back.

async undo()
returnsPromise<boolean>false when the action was not in effect
throwsserver's error when it refused the delete