Open Larinitus opened 2 months ago
incantations i think is under the character object, you have to set the character
Sorry I don't know how to do that. Am I not setting the character in V2? Or do I need to write "newCharCondition.character.incantations.push"?
I can't figure out how to add a new incantation to a player's list of learned incantations. I tried something like the following two but they don't work. What am I supposed to write?
V1: func: (gameState, event, setCurrentEvent) => { gameState.setIncantation(produce((newIncantation)=>{ newIncantation.incantations.push("basicAttackTest"); })); }
V2: func: (gameState, event, setCurrentEvent) => { gameState.setCharCondition(produce((newCharCondition)=>{ newCharCondition.incantations.push("basicAttackTest"); })); }