-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
9 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,22 @@ | ||
--[[ | ||
Name: MathParser.lua | ||
Author: ByteXenon [Luna Gilbert] | ||
Date: 2024-04-25 | ||
Date: 2024-06-22 | ||
---------------- | ||
Do not edit this file, this file is just | ||
a wrapper for the MathParser API. | ||
--]] | ||
|
||
local scriptPath, requirePath, localPath, oldPath | ||
if not LUAXEN_PACKER then | ||
-- Localize the path, so this file can be run from anywhere | ||
scriptPath = (debug.getinfo(1).source:match("@?(.*/)") or "") | ||
requirePath = scriptPath .. "./?.lua" | ||
localPath = scriptPath .. "./" | ||
oldPath = package.path | ||
package.path = package.path .. ";" .. requirePath | ||
end | ||
-- Localize the path, so this file can be run from anywhere | ||
local scriptPath = (debug.getinfo(1).source:match("@?(.*/)") or "") | ||
local requirePath = scriptPath .. "./?.lua" | ||
local localPath = scriptPath .. "./" | ||
local oldPath = package.path | ||
package.path = package.path .. ";" .. requirePath | ||
|
||
local MathParser = require("src/MathParser") | ||
|
||
if not LUAXEN_PACKER then | ||
-- Reset package.path | ||
package.path = oldPath | ||
end | ||
-- Reset package.path | ||
package.path = oldPath | ||
|
||
return MathParser |