mirror of
https://github.com/gooba42/adventureland.git
synced 2026-10-14 18:39:28 -05:00
Update runner_functions.js
Multi-character routines
This commit is contained in:
+14
-2
@@ -18,10 +18,10 @@ game={
|
|||||||
|
|
||||||
//#NOTE: Most new features are experimental - for #feedback + suggestions: https://discord.gg/X4MpntA [05/01/18]
|
//#NOTE: Most new features are experimental - for #feedback + suggestions: https://discord.gg/X4MpntA [05/01/18]
|
||||||
|
|
||||||
function start_character(name)
|
function start_character(name,code_slot_or_name)
|
||||||
{
|
{
|
||||||
// Loads a character in [CODE] mode
|
// Loads a character in [CODE] mode
|
||||||
parent.start_character_runner(name)
|
parent.start_character_runner(name,code_slot_or_name)
|
||||||
}
|
}
|
||||||
|
|
||||||
function command_character(name,code_snippet)
|
function command_character(name,code_snippet)
|
||||||
@@ -30,6 +30,13 @@ function command_character(name,code_snippet)
|
|||||||
parent.character_code_eval(name,code_snippet)
|
parent.character_code_eval(name,code_snippet)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function get_active_characters()
|
||||||
|
{
|
||||||
|
// States: "self", "starting","loading", "active", "code"
|
||||||
|
// Example: {"Me":"self","Protector":"loading"}
|
||||||
|
return parent.get_active_characters()
|
||||||
|
}
|
||||||
|
|
||||||
function is_pvp()
|
function is_pvp()
|
||||||
{
|
{
|
||||||
return G.maps[character.map].pvp || server.is_pvp;
|
return G.maps[character.map].pvp || server.is_pvp;
|
||||||
@@ -310,6 +317,11 @@ function say(message) // please use responsibly, thank you! :)
|
|||||||
parent.say(message,1);
|
parent.say(message,1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function pm(name,message) // please use MORE responsibly, thank you! :)
|
||||||
|
{
|
||||||
|
parent.private_say(name,message,0)
|
||||||
|
}
|
||||||
|
|
||||||
function move(x,y)
|
function move(x,y)
|
||||||
{
|
{
|
||||||
if(!can_walk(character)) return;
|
if(!can_walk(character)) return;
|
||||||
|
|||||||
Reference in New Issue
Block a user