Simply a copy paste error sorry about that. Also, the environment is completely different from c/cplusplus and my syntax highlighting package doesn't work properly. It would really help if it functioned correctly and errors were more helpful.
Anyways I see the issue, although I don't remember changing it. Me trying to modify const vars was due to me originally having vars in function( not const ). Trying to modify code I wrote in the trigger editor 10 months ago doesn't work out too well xD.
Anyways, thanks for the help, error parsing for just didnt make me think about variables, a undeclared variable nCivsGiven would be much more helpful.
Haha yea, I realized that, I just haven't programmed in base C for quite some time. My last 4 major projects were written in c++ xD.
This lack of intellisense is really impacting my productivity xD
Although, I am at a loss of why this code won't compile...
I didn't paste the whole function due to the fact that it is long and won't assist in finding the error.
void CIvGambleforPlayer (int p, region base)
{
unitgroup civillianGamble = UnitGroupEmpty();
int index = 1;
int nCivGiven;
fixed randomReal;
int randomInt;
I just removed/renamed all my functions with reserved names. It still crashes for some reason, I think it is because I include "LibGAx3" in my code. I am currently using battlenet to access that dependency when I load up my map. I know my script has a few errors, however, I cannot fix them unless I can compile the script to see my errors lol. Any ideas? I can let you see the script and my setup if that would be useful.
Thanks for the reply.
Well the thing is, I basically have the code for the whole map in my new MapScript.galaxy. My map has all the trigger stuff in there still. What are the steps I need to take to have a blank MapScript.galaxy and have all my other code in the other one and include it? I have no idea how to include the script as an auxillary and/or any steps necessary for my map.
How can I replace the base MapScript.galaxy for my map with a script I made from scratch? I cannot figure out how to do this... I overwrote the base in the folder and it didn't do anything. I also, tried opening the map and opening the script myself, I hit compile all and it crashes everytime...(compile causes editor to crash)
Does anyone have a copy of GAx3? The link on this site for download is broken. I don't want to have to log into battle net every time and now, it wont let me just to modify a map script.
0
Simply a copy paste error sorry about that. Also, the environment is completely different from c/cplusplus and my syntax highlighting package doesn't work properly. It would really help if it functioned correctly and errors were more helpful.
Anyways I see the issue, although I don't remember changing it. Me trying to modify const vars was due to me originally having vars in function( not const ). Trying to modify code I wrote in the trigger editor 10 months ago doesn't work out too well xD.
Anyways, thanks for the help, error parsing for just didnt make me think about variables, a undeclared variable nCivsGiven would be much more helpful.
0
Here you go :D
0
For some reason the tabs got really messed up in the paste...
0
@ImperialGood
Haha yea, I realized that, I just haven't programmed in base C for quite some time. My last 4 major projects were written in c++ xD.
This lack of intellisense is really impacting my productivity xD
Although, I am at a loss of why this code won't compile...
I didn't paste the whole function due to the fact that it is long and won't assist in finding the error.
void CIvGambleforPlayer (int p, region base)
{
unitgroup civillianGamble = UnitGroupEmpty();
int index = 1;
int nCivGiven;
fixed randomReal;
int randomInt;
UnitGroupLoopBegin(UnitGroup("CivilianFemale", p, RegionFromId(69), UnitFilter(0, 0, (1 << c_targetFilterMissile), (1 << (c_targetFilterDead - 32)) | (1 << (c_targetFilterHidden - 32))), 0));
for ( ; !UnitGroupLoopDone() ; UnitGroupLoopStep() )
{
civillianGamble = UnitGroup(UnitGetType(UnitGroupLoopCurrent()), p, RegionFromId(69), UnitFilter(0, 0, (1 << c_targetFilterMissile), (1 << (c_targetFilterDead - 32)) | (1 << (c_targetFilterHidden - 32))), 0);
}
UnitGroupLoopEnd();
nCivGiven = UnitGroupCount(civillianGamble, c_unitCountAlive);
if (nCivGiven > maxCivGamble)
{
nCivGiven = maxCivGamble;
}
if (nCivGiven >= 1)
{
for ( ; index <= nCivsGiven; index += 1 ) <- Error parsing for, possibly missing ;
{
UnitRemove(UnitGroupUnit(civillianGamble, index));
}
0
@FunkyUserName: Go
I guess function overloading isnt supported. Thanks for the help.
0
Okay I found the part that crashes the editor. It is my trigger declarations... lol. I have no idea what may be wrong.
trigger ModeChosen;
trigger ModeChosen2;
trigger Voting;
trigger SkinStuff;
trigger OpenSkinMenu;
trigger CloseSkinMenu;
trigger SpawnPlayer1;
trigger SpawnPlayer2;
trigger SpawnPlayer3;
trigger SpawnPlayer4;
trigger SpawnPlayer5;
trigger SpawnPlayer6;
trigger InitializeTeirs;
trigger CivGamble;
trigger SpawnZergling;
trigger SpawnSCV;
trigger SpawnBaneling;
trigger SpawnMedic;
trigger SpawnWidowMine;
trigger SpawnPreserver;
trigger SpawnObserver;
trigger SpawnAlmostDeadPenguin;
trigger SpawnScourge;
trigger SpawnFirebat;
trigger SpawnOracle;
trigger SpawnSentry;
trigger SpawnMarine;
trigger SpawnWarpPrism;
trigger SpawnRoach;
trigger SpawnCorruptor;
trigger SpawnVulture;
trigger SpawnReaper;
trigger SpawnHydralisk;
trigger SpawnHighTemplar;
trigger SpawnDarkTemplar;
trigger SpawnLurker;
trigger SpawnStalker;
trigger SpawnPhoenix;
trigger SpawnRaven;
trigger SpawnMarauder;
trigger SpawnBattleCruiser;
trigger SpawnViper;
trigger SpawnTank;
trigger SpawnViking;
trigger SpawnVoidRay;
trigger SpawnUltralisk;
trigger SpawnImmortal;
trigger SpawnBanshee;
trigger SpawnMutalisk;
trigger SpawnCarrier;
trigger SpawnGoliath;
trigger SpawnGhost;
trigger SpawnSwarmHost;
trigger SpawnThor;
trigger SpawnInfestor;
trigger SpawnColossus;
trigger SpawnBroodLord;
trigger SpawnTempest;
trigger SpawnScout;
trigger SpawnMinerals;
trigger CreateLeviathanMid;
trigger DestroyAllPhotons;
trigger ForceGoBuy;
trigger ForceStopBuy;
trigger ForceMiddleBuy;
trigger Turntechpenguinspawnoff;
trigger Turntechpenguinspawnon;
trigger PlayerLeaves;
trigger Initialization;
trigger BlowUpBaseDefenses;
trigger ResetScore;
trigger UnitsEvents;
trigger EventsUnits;
trigger CivEscapes;
trigger Displayinfo;
trigger Help;
trigger TransferCivs;
trigger SpawnBonusMinerals;
trigger BonusRes;
trigger GiveResTeam;
trigger GiveRes;
trigger ForceGo;
trigger ForceInvulnerableOff;
trigger ForceStop;
trigger ForceMiddle;
trigger TopLeft;
trigger TopRight;
trigger TopMid;
trigger BottomLeft;
trigger BottomRight;
trigger BottomMid;
trigger Mid;
trigger Player1Enemy;
trigger Player2Enemy;
trigger Player3Enemy;
trigger Player4Enemy;
trigger Player5Enemy;
trigger Player6Enemy;
trigger TutorialInitialization;
trigger TutorialBClicked;
trigger Tutorial;
trigger UnitHealthInit;
trigger HealthUprade;
trigger ArmorUpgrade;
trigger SpawnRateUpgradeFast;
trigger SpawnRateUpgradeFaster;
trigger SpawnRateUpgradeNorm;
Any idea what is wrong with the above?
0
So how can I disable all animations for single unit?(without making a separate actor and unit)
0
I just removed/renamed all my functions with reserved names. It still crashes for some reason, I think it is because I include "LibGAx3" in my code. I am currently using battlenet to access that dependency when I load up my map. I know my script has a few errors, however, I cannot fix them unless I can compile the script to see my errors lol. Any ideas? I can let you see the script and my setup if that would be useful.
0
@ImperialGood: Go
Okay I saved map in unpacked format. I made a custom script and included my .galaxy file in it. I hit save and it crashes. Any ideas?
0
@ImperialGood: Go
Can you give me an example of the import statement? I have never used it in galaxy. Do you mean include?
0
@ImperialGood: Go
Thanks for the reply. Well the thing is, I basically have the code for the whole map in my new MapScript.galaxy. My map has all the trigger stuff in there still. What are the steps I need to take to have a blank MapScript.galaxy and have all my other code in the other one and include it? I have no idea how to include the script as an auxillary and/or any steps necessary for my map.
0
How can I replace the base MapScript.galaxy for my map with a script I made from scratch? I cannot figure out how to do this... I overwrote the base in the folder and it didn't do anything. I also, tried opening the map and opening the script myself, I hit compile all and it crashes everytime...(compile causes editor to crash)
0
Does anyone have a copy of GAx3? The link on this site for download is broken. I don't want to have to log into battle net every time and now, it wont let me just to modify a map script.
0
@ImperialGood: Go
Thanks for the reply! I think I almost have galaxy down( except for function/method names ).
0
Does implicit casting from char to int work?(want to store player as a char)