mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-06 06:01:46 +00:00
More or less standardised separator comments in the code
This commit is contained in:
@@ -1,3 +1,6 @@
|
||||
#===============================================================================
|
||||
#
|
||||
#===============================================================================
|
||||
module PBDebug
|
||||
@@log = []
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
#===============================================================================
|
||||
# To use the console, use the executable explicitly built with the console
|
||||
# enabled on Windows. On Linux and macOS, just launch the executable directly
|
||||
# from a terminal.
|
||||
#===============================================================================
|
||||
module Console
|
||||
def self.setup_console
|
||||
return unless $DEBUG
|
||||
@@ -33,6 +35,9 @@ module Console
|
||||
end
|
||||
end
|
||||
|
||||
#===============================================================================
|
||||
#
|
||||
#===============================================================================
|
||||
module Kernel
|
||||
def echo(string)
|
||||
return unless $DEBUG
|
||||
@@ -48,14 +53,15 @@ end
|
||||
Console.setup_console
|
||||
|
||||
#===============================================================================
|
||||
# Console message formatting
|
||||
# Console message formatting
|
||||
#===============================================================================
|
||||
module Console
|
||||
module_function
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# echo string into console (example shorthand for common options)
|
||||
# echo string into console (example shorthand for common options)
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
# heading 1
|
||||
def echo_h1(msg)
|
||||
echoln markup_style("*** #{msg} ***", text: :brown)
|
||||
@@ -130,6 +136,7 @@ module Console
|
||||
#-----------------------------------------------------------------------------
|
||||
# Markup options
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
def string_colors
|
||||
{
|
||||
default: "38", black: "30", red: "31", green: "32", brown: "33",
|
||||
|
||||
@@ -4,6 +4,9 @@
|
||||
class Reset < Exception
|
||||
end
|
||||
|
||||
#===============================================================================
|
||||
#
|
||||
#===============================================================================
|
||||
class EventScriptError < Exception
|
||||
attr_accessor :event_message
|
||||
|
||||
@@ -13,6 +16,9 @@ class EventScriptError < Exception
|
||||
end
|
||||
end
|
||||
|
||||
#===============================================================================
|
||||
#
|
||||
#===============================================================================
|
||||
def pbGetExceptionMessage(e, _script = "")
|
||||
return e.event_message.dup if e.is_a?(EventScriptError) # Message with map/event ID generated elsewhere
|
||||
emessage = e.message.dup
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
#===============================================================================
|
||||
# The Kernel module is extended to include the validate method.
|
||||
#===============================================================================
|
||||
module Kernel
|
||||
private
|
||||
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
#===============================================================================
|
||||
# The Deprecation module is used to warn game & plugin creators of deprecated
|
||||
# methods.
|
||||
#===============================================================================
|
||||
module Deprecation
|
||||
module_function
|
||||
|
||||
@@ -19,7 +21,10 @@ module Deprecation
|
||||
end
|
||||
end
|
||||
|
||||
# The Module class is extended to allow easy deprecation of instance and class methods.
|
||||
#===============================================================================
|
||||
# The Module class is extended to allow easy deprecation of instance and class
|
||||
# methods.
|
||||
#===============================================================================
|
||||
class Module
|
||||
private
|
||||
|
||||
|
||||
Reference in New Issue
Block a user