[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to "sandbox" scripts

From: Brad Medeiros
Subject: How to "sandbox" scripts
Date: Thu, 16 Apr 2020 23:27:51 -0700

Hi All - I haven't been active on these mailing lists, but I've been reading them for a bit of time now.   Nice to actually reach out!

I am building a simple game engine and I'm embedding guile in it to do game scripting. 
One property I want is the ability to write scripts where each defines a function - eg onFrame, onMouseMove, and so on, and then call these.

Currently I do this via calling scm_c_primitive_load to actually run the initial evaluation and then I call back into hooks - scm_call_0(scm_c_lookup("onFrame"));  So far it has been working great.

What I would like to do, is to be able to load multiple scripts that define the same set of functions, and then iterate over them calling each's onFrame.   Ideally these should be sandboxed as much as possible.  

Any ideas of how to do this? 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]