GaijinEntertainment / quirrel

Quirrel - Gaijin Entertainment dynamic script language
http://quirrel.io
MIT License
157 stars 33 forks source link

Interactive console(SQ) doesn't include baselib #95

Closed DFelipehDEV closed 2 months ago

DFelipehDEV commented 3 months ago

When running baselib functions(print, println, freeze...) in the SQ interpreter, they appear as not included and as variable errors image

VasiliyRyabtsev commented 3 months ago

Thank you for your report! I will fix this in the next few days. Unfortunately "interactive" mode in SQ interpreter never was very useful, and it is less useful in the current Quirrel version because of locally scoped variables. It can be reworked, but needs a serious redesign, and it will be more complex than a trivial sq_compile()/sq_call() pair.

DFelipehDEV commented 3 months ago

Hey! Yeah i agree that the console isn't very useful beyond simple tasks like call functions. My goal was to understand how to embed quirrel. Instead of a rework, I would suggest just provide simple samples to demonstrate how it works

VasiliyRyabtsev commented 3 months ago

Fixed in dcef127ab8c3543473bdb058afe27c37a993d014