System Function

Aus EEP Handbuch
Version vom 7. September 2018, 12:43 Uhr von Marc Horstmann (Diskussion | Beiträge)

(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Wechseln zu: Navigation, Suche
clearlog() clearlog()
type: function
    clearlog()
                
caller: script
defined in: EEP
parameters: none
return: none
requires: EEP 10.2 plug-in 2
purpose: Clears the Lua event window.


print() print( "Text1", "Text2", ..., TextN )
type: function
    print("The time now is: ",EEPTimeH,":",EEPTimeM)
                
caller: script
defined in: EEP
parameters: multiple
return: one
requires: EEP 10.2 plug-in 2
purpose: Writes arguments to Lua event window (activate window in EEP properties)
notes:
  • Number types are converted to strings.
  • Accepts multiple arguments. Use comma as separator. Line feed with \n.
  • Returns the entire print text as one string.


EEPMain() EEPMain()
type: function
    function EEPMain()
        return 1
    end
                
caller: EEP
defined in: script
parameters: none
returns: one
requires: EEP 10.2 plug-in 2
purpose: This function is called by EEP 5 times per second (i.e. every 200 milliseconds); useful for all actions that require constant repeats.
notes:
  • Declaration of this function is mandatory in every script.
  • The function is called by EEP without any parameters.
  • The function must return any number other than 0 to be called again.
  • Returning a 0 turns off the repeated calling of this function. Any other functions in yourscript remain active.
  • If this function returns something other than a number, EEP will cease to use the script.


EEPPause() EEPPause( Status )
type: function
    Pause = EEPPause( 1 )
                
caller: script
defined in: EEP
parameters: one
returns: one
requires: EEP 14 plug-in 1
purpose: Activates and deactivates the break-satus of EEP.
notes:
  • Status = 0 EEP resumes the simulation.
  • Status = 1 the simulation gets stopped.
  • Status = 2 the simulation and the LUA-scrip execution are stopped. To resume these, user will have to press the P-key.
  • Return value is 0, if the simulation resumes or 1, if it was stopped.


EEPSetTime() EEPSetTime(Hour,Minute,Second)
type: function
    EEPSetTime( 14, 35, 2 )
                
caller: script
defined in: EEP
parameters: three
returns: one
requires: EEP 14.2 Plug-In 2
purpose: Changes the EEP-time.
notes:
  • Argument 1 sets the hours.
  • Argument 2 sets the minutes.
  • Argument 3 sets the seconds.
  • All three arguments are mandatory.
  • The return value is true on success, otherwise false.