Hello again gametoast. Im having a problem with my turrets. To make my map I edited the shiped geonosis map, so the geonosis turret was already in my lua. Im trying to load the beam turret into my map, so I add it to my lua (I put a comma after the geo turrent). Then when I start my map it freezes for over two minutes (I load my game through steam). I dont know whats wrong. Im guessing my lua is good because when I delet the beam line and take away the comma the geo turret still works.
Re: Turret lua error
Posted: Thu Jul 11, 2013 7:57 pm
by Marth8880
Please post said LUA.
Re: Turret lua error
Posted: Sat Jul 13, 2013 1:47 pm
by Lorul1
Heres my lua. i know its A LITTLE crazy, there are still many fixes to come.
Hidden/Spoiler:
[code]--
-- Copyright (c) 2005 Pandemic Studios, LLC. All rights reserved.
--
-- load the gametype script
ScriptCB_DoFile("ObjectiveConquest")
ScriptCB_DoFile("setup_teams")
---------------------------------------------------------------------------
-- FUNCTION: ScriptInit
-- PURPOSE: This function is only run once
-- INPUT:
-- OUTPUT:
-- NOTES: The name, 'ScriptInit' is a chosen convention, and each
-- mission script must contain a version of this function, as
-- it is called from C to start the mission.
---------------------------------------------------------------------------
--This sets up the actual objective. This needs to happen after cp's are defined
conquest = ObjectiveConquest:New{teamATT = ATT, teamDEF = DEF, text = "level.geo1.objectives.conquest", multiplayerRules = true}
--This adds the CPs to the objective. This needs to happen after the objective is set up
conquest:AddCommandPost(cp1)
conquest:AddCommandPost(cp2)
conquest:AddCommandPost(cp3)
conquest:AddCommandPost(cp4)
conquest:AddCommandPost(cp5)
conquest:AddCommandPost(cp6)
conquest:AddCommandPost(cp7)
conquest:AddCommandPost(cp8)
conquest:AddCommandPost(cp9)
conquest:AddCommandPost(cp10)
end
function ScriptInit()
StealArtistHeap(800*1024)
-- Designers, these two lines *MUST* be first.
SetPS2ModelMemory(3500000)
ReadDataFile("ingame.lvl")
-- REP Attacking (attacker is always #1)
local REP = 1
local CIS = 2
-- These variables do not change
local ATT = 1
local DEF = 2
SetMemoryPoolSize ("Combo",64) -- should be ~ 2x number of jedi classes
SetMemoryPoolSize ("Combo::State",256) -- should be ~12x #Combo
SetMemoryPoolSize ("Combo::Transition",256) -- should be a bit bigger than #Combo::State
SetMemoryPoolSize ("Combo::Condition",256) -- should be a bit bigger than #Combo::State
SetMemoryPoolSize ("Combo::Attack",150) -- should be ~8-12x #Combo
SetMemoryPoolSize ("Combo::DamageSample",4086) -- should be ~8-12x #Combo::Attack
SetMemoryPoolSize ("Combo::Deflect",64) -- should be ~1x #combo
SetMemoryPoolSize("Music", 40)
By the way, if the lua cant shrink like all the other luas I need to know how to do this (through gametoast) I dont want to break any rules. im a little new.