MCPcopy Create free account
hub / github.com/DFHack/dfhack / on_state_change

Method on_state_change

library/PluginManager.cpp:582–593  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

580}
581
582command_result Plugin::on_state_change(color_ostream &out, state_change_event event)
583{
584 command_result cr = CR_NOT_IMPLEMENTED;
585 access->lock_add();
586 if(state == PS_LOADED && plugin_onstatechange)
587 {
588 cr = plugin_onstatechange(out, event);
589 Lua::Core::Reset(out, "plugin_onstatechange");
590 }
591 access->lock_sub();
592 return cr;
593}
594
595command_result Plugin::save_world_data(color_ostream &out)
596{

Callers 1

OnStateChangeMethod · 0.80

Calls 2

lock_addMethod · 0.80
lock_subMethod · 0.80

Tested by

no test coverage detected