Yes it is possible to write it like this:
nClass = CLASS_TYPE_JEDISENTINEL;
But only for local variables. For Globals you should use the SetGlobal functions.
My Jedi Script works very well. But it is a function, so you still have to start this procedure.
I'm setting those globals cause i DON'T want that the player has to make those pre-jedi quests on Dantooine.
You could start my script like this to get it running: