Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- A basic encounter script skeleton you can copy and modify for your own creations.
- encountertext = "Chara bloquea el camino!" --Modify as necessary. It will only be read out in the action select screen.
- nextwaves = {}
- arenasize = {155, 130}
- enemies = {
- "Chara (es)"
- }
- enemypositions = {
- {0, 0}
- }
- deathtext = {
- "[voice:v_sschara]E-ey! [w:10]Humano? [w:10]E-estas ahi?",
- "[voice:v_sschara][waitall:2][effect:shake,2]O-oh no..."
- }
- attacknum = 0
- caja = 0
- tartacount = 0
- nieve = 0
- turnonieve = 0
- -- A custom list with attacks to choose from. Actual selection happens in EnemyDialogueEnding(). Put here in case you want to use it.
- possible_attacks = {"bullettest_chaserorb"}
- function EncounterStarting()
- -- If you want to change the game state immediately, this is the place.
- Audio.LoadFile("knifetrousle")
- Audio.Play("knifetrousle")
- Misc.WindowName = "StorySwap"
- Inventory.AddCustomItems({"Tarta", "Trz. Nieve x3", "Trz. Nieve x2", "Trz. Nieve", "Bipolo", "Unipolo", "Cnj. Canela x2", "Cnj. Canela"}, {0,0,0,0,0,0,0,0})
- Inventory.SetInventory({"Tarta", "Trz. Nieve x3", "Bipolo", "Cnj. Canela x2"})
- require "Animations/animchara"
- Player.name = "BLOOKY"
- end
- function EnemyDialogueStarting()
- -- Good location for setting monster dialogue depending on how the battle is going.
- end
- function Update()
- Player.hp = 20
- end
- function EnemyDialogueEnding()
- attacknum = attacknum + 1
- if attacknum == 1 then
- nextwaves = {"wave1"}
- elseif attacknum == 2 then
- nextwaves = {"wave2"}
- elseif attacknum == 3 then
- nextwaves = {"wave3"}
- elseif attacknum == 4 then
- nextwaves = {"wave4"}
- elseif attacknum == 5 then
- nextwaves = {"wave5"}
- elseif attacknum == 6 then
- nextwaves = {"wave6"}
- elseif attacknum == 7 then
- nextwaves = {"wave7"}
- elseif attacknum == 8 then
- nextwaves = {"wave8"}
- elseif attacknum == 9 then
- nextwaves = {"final1"}
- elseif attacknum == 10 then
- nextwaves = {"nada"}
- end
- end
- function DefenseEnding() --This built-in function fires after the defense round ends.
- end
- function HandleSpare()
- State("ENEMYDIALOGUE")
- end
- function HandleItem(ItemID)
- if ItemID == "TARTA" then
- Player.heal(999)
- BattleDialog({"Comes la Tarta.\r[w:5]Recuperas todo tu HP!"})
- elseif ItemID == "TRZ. NIEVE X3" then
- Player.heal(999)
- BattleDialog({"Comes el Trozo de Nieve.[w:5]\rRecuperas todo tu HP!"})
- Inventory.AddItem("Trz. Nieve x2", 3)
- elseif ItemID == "TRZ. NIEVE X2" then
- Player.heal(999)
- BattleDialog({"Comes el Trozo de Nieve.[w:5]\rRecuperas todo tu HP!"})
- Inventory.AddItem("Trz. Nieve", 3)
- elseif ItemID == "TRZ. NIEVE" then
- Player.heal(999)
- BattleDialog({"Comes el Trozo de Nieve.[w:5]\rRecuperas todo tu HP!"})
- elseif ItemID == "BIPOLO" then
- if Player.hp >= 9 then
- Player.heal(11)
- BattleDialog({"Comes la mitad del Bipolo.[w:5]\rRecuperas todo tu HP!"})
- Inventory.AddItem("Unipolo", 4)
- elseif Player.hp <= 8 then
- Player.heal(11)
- BattleDialog({"Comes la mitad del Bipolo.[w:5]\rRecuperas 11 de HP!"})
- end
- elseif ItemID == "UNIPOLO" then
- if Player.hp >= 9 then
- Player.heal(11)
- BattleDialog({"Comes la ultima mitad del Bipolo.[w:5]\rRecuperas todo tu HP!"})
- elseif Player.hp <= 8 then
- Player.heal(11)
- BattleDialog({"Comes la ultima mitad del Bipolo.[w:5]\rRecuperas 11 de HP!"})
- end
- elseif ItemID == "CNJ. CANELA X2" then
- Player.heal(999)
- BattleDialog({"Comes el Conejo de Canela.[w:5]\rRecuperas todo tu HP!"})
- Inventory.AddItem("Cnj. Canela", 5)
- elseif ItemID == "CNJ. CANELA" then
- Player.heal(999)
- BattleDialog({"Comes el Conejo de Canela.[w:5]\rRecuperas todo tu HP!"})
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement