v22755 (05/11/01):

- (optimization) Damage Decal toggle applies to ALL damage decals now. This improves performance on video cards with lower VRAM. Those cards should turn this feature OFF for best gameplay.

- (optimization) Dynamic lighting now fades with distance so that systems do less calculations on lights that make little or no difference anyway.

- (optimization) The following missions were edited/revised in order to achieve much higher framerates in-game. They are:
	Death Birds Fly
	Dust to Dust
	Recalascence
	Reversion
	Riverdance

- (optimization) There is now a PARTICLE DENSITY slider on the GRAPHICS menu that allows you to turn down the number of particles used in explosions and weapon effects. Systems with low VRAM should turn this down as low as possible. The effects will still look good, but will use many less polygons and alpha translucencies.

- (optimization) The force shield effect on players and objects has been greatly simplified. The old effect was hammering the frame rates on older video cards when played. This new effect greatly speeds gameplay on all cards, and particularly on Voodoo cards.

- (memory leak) Memory leaks were located and eradicated. This most likely was the cause of the "degradation over time" that folks were experiencing on their servers.

- (bug fix) "Vote Spamming" has been prevented in-game.

- (bug fix) Moved some of the CD check from script into code, where it should be.

- (bug fix) The "sticking" mouse button problem is now fixed.

- (bug fix) Deployables are now easier to place on walls and other surfaces. There were some inconsistencies on which surfaces could be placed upon and those are now resolved.

- (bug fix) There was a bug that prevented users from deleting some Server Filters. That is resolved now.

- (bug fix) There was a Siege bug where a base item (like a turret) could be destroyed, and then repaired, but it would no longer receive power after being repaired. That is now fixed. The items will receive power correctly after being repaired.

- (bug fix) Resolved the Team Damage OFF situation where friendly troops could destroy permanent "base" objects.

- (bug fix) Removed a packet overrun in the net code that *could* have allowed hackers to bring down servers. This had not occurred to date and is now prevented.

- (bug fix) Deployable inventory stations can no longer be deployed directly next to each other. They must be at least 20 meters apart in order to be deployed properly.

- (bug fix) Ejection speed increased slightly to more easily accomodate jumping out of moving vehicles.

- (bug fix) Many team damage fixes occurred. When Team Damage is OFF the following are now true: Friendly teammates are no longer prevented from destroying deployables. The ELF will no longer drain energy from friendly players. If a friendly player blinds another friendly player with Whiteout grenades, then a message is displayed in the Chat HUD so that the blinded person knows who did it. (There are more Team Damage changes coming in the next patch.)

- (bug fix) Medium now has a standard loadout of 12 grenades in the grenade launcher instead of 10. Light: 10; Medium: 12; Heavy: 15.

- (bug fix) Deployable pulse sensors now have a range of 150m instead of 120m to make them a more attractive option to deploy.

- (bug fix) Fixed an indoor turret proximity bug introduced in the last patch.

- (improvement) Flag captures are now worth 100 points (for the team), instead of 1 point. Additionally, each time someone grabs the flag *from the enemy flag stand* they will gain 1 point (for the team), regardless of whether they actually capture it or not. You will ONLY get this single point if the flag was actually on the flagstand. You will NOT get the point by touching the flag anywhere else on the field. This change will help prevent tie situations and will reward aggressive offensive play.
NOTE: The "touch" point can only be gained once every 20 seconds...so a "scrum" around the flag base will not result in a large group of points being gained.

- (improvement) Siege: Alcatraz. The generators have been moved around a bit. There are two entrances to that base. One is the "front door" and the other is the "back door". (The back door is the one that has a team-pass-only force field blocking enemies from the switch room.) There is now an upper generator down the chute from the "front door" that powers the "back door" force field. Additionally, there is a solar panel outside that powers the base turrets and sentry turrets. None of these generators have to be destroyed to get to the switch, but their destruction makes it MUCH easier to do so. There are four generators total on this map (all are waypointed now), and the destruction of all four is necessary before the base power will go down.

- (improvement) Siege: Caldera. The generator has been moved out of the switch room and into the very big main room that has the inventory stations in it. It is no longer necessary to destroy the generators in a particular sequence. Destroying the two main generators (Primary and Secondary) will drop the force field that protects the switch. Both gens must be down in order for the switch force field to drop.

- (improvement) Added "quickbuy" keyboard shortcuts to use at vehicle station. (Default keys are the 1-6 number keys. 1 is the top vehicle on the list, 6 is the bottom vehicle on the list).
NOTE: These key bindings are not currently editable. However, since you are on the vehicle purchase pad when they are in effect, they cannot interfere with any custom keys you've created, so you should have no problems.

- (improvement) Team Damage ON/OFF can be changed by Admins/SuperAdmins as well as being voted on by players. If you are an Admin or SuperAdmin, then just go to Lobby and look up where the "Vote" options are listed. There are options there to toggle the Team Damage flag. Regular players can also Vote to Enable/Disable Team Damage in the same spot.

- (improvement) Default server prefs have been changed so that the default time limit is now 30 minutes (instead of 20) and Team Damage is OFF.

- (improvement) Fixed buddy filter. You can now use the Filter option on the JOIN screen to find games that have players in them that are listed on your buddy list. (Use the Email or Warrior Browser functions to add/remove people from your buddy list.)
NOTE: We feel that there is an issue that may be related to NAT (Network Address Translation). Sierra QA uses public IP addresses on it's internal network that are not routable on the Internet.  They experience a problem that occurs when anyone inside their firewall uses the Internet for anything, their internal address is "changed" to a legal external address. In their case, they use "many to one" NAT, so everyone appears to be the same address outside our walls. This issue prevents Sierra QA from seeing "buddies" that are on systems *inside* their firewall (they can see "buddies" on external servers just fine). We are hypothesizing that it is NAT that is causing the buddy list lookup to fail internally. We are continuing to work on this.
ALSO NOTE: This feature works correctly for everyone else.

- (improvement) You can now add a player to your server admin lists (so that server admins can auto-admin players when they join a server, if desired). How this is done: If you are a SuperAdmin (owner of the server), you can go into the lobby and right-click on a player's name. You will then have the ability to add them to your Admin or SuperAdmin lists.

- (improvement) Master Server list no longer insists on keeping your current game highlighted while refreshing a query. This allows you to page up and down more easily on the list while it is refreshing.

- (improvement) Added "Team Damage ON/OFF" and "Windows/Linux" as options for creating new Server Filters.

- (improvement) Missile reticle is improved aesthetically. This is part 1 of 2 of the missile reticle changes. The second part will be in the next patch.

- (community) Made changes to Tribe Forums to make posting new topics work better with the current cache architecture.

- (community) Fixed buttons on Tribe/Warrior Browser to reflect visitors membership in tribe

- (community) Changed NEWS button on Tribe page to OPTIONS, added links to Tribe Forum, Tribe Public Chat and Tribe Private Chat.

- (community) Added "EMail" and "Add To Buddylist" options into the right click menu in the Chat Channel member list.

- (community) Changed layout of right click menu's in the Community for easier understandability.

- (community) Added Moderator functions to the T2 Community - allows post removal, ability to send warnings and execute ban's to the perp.

- (community) Added confirmation box to the News page on Submit News - explains purpose and requires yes/no.

- (community) Upgraded Forum Cache version

- (community) Added ability to Lock Topic for Moderators

- (community) Added locking for posts where Topic is already in cache.

- (community) Implemented a ban structure on the Database

- (community) Fixed DBProxy thread disconnections - removed blank error boxes.

- (community) Fixed bug in Blocking Email Senders
This commit is contained in:
Robert MacGregor 2017-07-17 23:16:06 -04:00
parent a7153c654d
commit b58ea2862a
62 changed files with 3121 additions and 4953 deletions

View file

@ -431,7 +431,9 @@ function ChatRoomMemberList::onRightMouseDown(%this,%column,%row,%mousePos)
else
{
if (strcmp(ChatMemberPopup.member.displayName,$IRCClient::currentChannel.getName()))
{
ChatMemberPopup.add("Chat",2);
}
if ($IRCClient::currentChannel.getFlags(%im) & $PERSON_OPERATOR)
{
@ -445,6 +447,11 @@ function ChatRoomMemberList::onRightMouseDown(%this,%column,%row,%mousePos)
ChatMemberPopup.add("Unmute",6);
else
ChatMemberPopup.add("Mute",6);
ChatMemberPopup.add( "--------------------",-1);
ChatMemberPopup.add( "TMail", 10 );
ChatMemberPopup.add( "Add To Buddylist",11);
for (%i = 1; %i < $IRCClient::channels.getCount(); %i++)
{
%c = $IRCClient::channels.getObject(%i);
@ -476,6 +483,7 @@ function ChatPrivate()
//------------------------------------------------------------------------------
function ChatMemberPopup::onSelect(%this,%id,%text)
{
%member = getSubStr(ChatMemberPopup.member.displayName,0,strlen(ChatMemberPopup.member.displayname)-strlen(nextToken(ChatMemberPopup.member.displayname,name,"^"))-1);
switch( %id )
{
case 0: // Set Back
@ -494,6 +502,11 @@ function ChatMemberPopup::onSelect(%this,%id,%text)
IRCClient::kick(ChatMemberPopup.member,$pref::IRCClient::banmsg);
case 6: // Mute/Unmute
IRCClient::ignore(ChatMemberPopup.member,!(ChatMemberPopup.member.flags & $PERSON_IGNORE));
case 10: // TMail
LinkEMail(%member);
case 11: // Add To Buddylist
MessageBoxYesNo("CONFIRM","Add " @ %member @ " to Buddy List?",
"LinkAddBuddy(\"" @ %member @ "\",TWBText,\"addBuddy\");","");
default: // Invite
IRCClient::invite(ChatMemberPopup.member,%id);
}
@ -832,7 +845,7 @@ function IRCClient::notify(%event)
$IRCClient::nextChannel = 0;
}
ChatTabView.removeTab($IRCClient::deletedChannel);
case IDIRC_INVITED:
case IDIRC_INVITED: //invited to join existing channel.
//MessageBoxOKCancel("Invite", "You have been invited to channel " @ IRCClient::displayChannel($IRCClient::invitechannel) @ " by " @ $IRCClient::inviteperson @ ".", "IRCClient::join($IRCClient::invitechannel);");
IRCClient::newMessage($IRCClient::CurrentChannel, "You have been invited to channel " @ $IRCClient::invitechannel @ " by " @ $IRCClient::inviteperson @ ".");
case IDIRC_BAN_LIST:

View file

@ -39,15 +39,24 @@ function ChooseFilterDlg::newFilter( %this )
%this.editFilterIndex = CF_FilterList.rowCount();
FilterEditName.setValue( "New Filter" );
FilterEditMinPlayers.setValue( 0 );
FilterEditMaxPlayers.setValue( 255 );
FilterEditGameType.setText( "Any" );
FilterEditMissionType.setText( "Any" );
for ( %i = 0; isObject( "FilterEditLocMask" @ %i ); %i++ )
( "FilterEditLocMask" @ %i ).setValue( true );
FilterEditMinPlayers.setValue( 0 );
FilterEditMaxPlayers.setValue( 255 );
FilterEditMaxBots.setValue( 16 );
FilterEditMinCPU.setValue( 0 );
FilterEditUsePingTgl.setValue( false );
FilterEditMaxPing.setValue( 50 );
FilterEditMaxPing.setVisible( false );
FilterEditTDOnTgl.setValue( false );
FilterEditTDOffTgl.setValue( false );
FilterEditWindowsTgl.setValue( false );
FilterEditLinuxTgl.setValue( false );
FilterEditDedicatedTgl.setValue( false );
FilterEditNoPwdTgl.setValue( false );
FilterEditCurVersionTgl.setValue( false );
for ( %i = 0; isObject( "FilterEditLocMask" @ %i ); %i++ )
( "FilterEditLocMask" @ %i ).setValue( true );
Canvas.pushDialog( FilterEditDlg );
}
@ -115,6 +124,28 @@ function ChooseFilterDlg::editFilter( %this )
FilterEditMaxBots.setValue( %maxBots );
FilterEditMinCPU.setValue( %minCPU );
if ( %flags & 8 )
{
FilterEditWindowsTgl.setValue( true );
FilterEditLinuxTgl.setValue( false );
}
else
{
FilterEditWindowsTgl.setValue( false );
FilterEditLinuxTgl.setValue( %flags & 4 );
}
if ( %flags & 16 )
{
FilterEditTDOnTgl.setValue( true );
FilterEditTDOffTgl.setValue( false );
}
else
{
FilterEditTDOnTgl.setValue( false );
FilterEditTDOffTgl.setValue( %flags & 32 );
}
FilterEditDedicatedTgl.setValue( %flags & 1 );
FilterEditNoPwdTgl.setValue( %flags & 2 );
FilterEditCurVersionTgl.setValue( %flags & 128 );
@ -142,6 +173,10 @@ function ChooseFilterDlg::saveFilter( %this )
%minCPU = FilterEditMinCPU.getValue();
%flags = FilterEditDedicatedTgl.getValue()
| ( FilterEditNoPwdTgl.getValue() << 1 )
| ( FilterEditLinuxTgl.getValue() << 2 )
| ( FilterEditWindowsTgl.getValue() << 3 )
| ( FilterEditTDOnTgl.getValue() << 4 )
| ( FilterEditTDOffTgl.getValue() << 5 )
| ( FilterEditCurVersionTgl.getValue() << 7 );
%row = %filterName TAB %gameType TAB %misType
TAB %minPlayers TAB %maxPlayers TAB %regionCode
@ -161,7 +196,7 @@ function ChooseFilterDlg::deleteFilter( %this )
return;
%row = CF_FilterList.getRowNumById( %rowId );
%lastFilter = CF_FilterList.rowCount() - 3;
%lastFilter = CF_FilterList.rowCount() - 4;
while ( ( %nextRow = CF_FilterList.getRowTextById( %rowId + 1 ) ) !$= "" )
{
@ -331,6 +366,34 @@ function addMissionType(%type)
FilterEditMissionType.add( %type, 0 );
}
//------------------------------------------------------------------------------
function FilterEditTDOnTgl::onAction( %this )
{
if ( %this.getValue() && FilterEditTDOffTgl.getValue() )
FilterEditTDOffTgl.setValue( false );
}
//------------------------------------------------------------------------------
function FilterEditTDOffTgl::onAction( %this )
{
if ( %this.getValue() && FilterEditTDOnTgl.getValue() )
FilterEditTDOnTgl.setValue( false );
}
//------------------------------------------------------------------------------
function FilterEditWindowsTgl::onAction( %this )
{
if ( %this.getValue() && FilterEditLinuxTgl.getValue() )
FilterEditLinuxTgl.setValue( false );
}
//------------------------------------------------------------------------------
function FilterEditLinuxTgl::onAction( %this )
{
if ( %this.getValue() && FilterEditWindowsTgl.getValue() )
FilterEditWindowsTgl.setValue( false );
}
//------------------------------------------------------------------------------
// Make sure we still have at least one region selected:
function FilterEditDlg::checkRegionMasks( %this, %lastIndex )

View file

@ -370,7 +370,8 @@ function GMJ_Browser::onDatabaseRow( %this, %row, %isLastRow, %key )
function GMJ_Browser::onSelect( %this, %address )
{
GMJ_JoinBtn.setActive( true );
GMJ_RefreshServerBtn.setActive( true );
if ( !isServerQueryActive() )
GMJ_RefreshServerBtn.setActive( true );
$JoinGamePassword = "";
$JoinGameAddress = %address;
@ -489,7 +490,7 @@ function ServerInfoDlg::update( %this )
// Fill in the content window:
%content = GMJ_Browser.getServerContentString();
SI_ContentWindow.fill( %content );
%refreshable = true;
%refreshable = !isServerQueryActive();
}
else
{
@ -506,7 +507,7 @@ function ServerInfoDlg::update( %this )
case "timedOut":
%temp = "<spush><color:DC1A1A>Timed out.<spop>";
SI_ContentWindow.setText( "Not available." );
%refreshable = true;
%refreshable = !isServerQueryActive();
}
%infoText = %infoText NL "<lmargin:0><spush>" @ %this.headerStyle @ "STATUS: <spop><lmargin:70>" TAB %temp;
}

View file

@ -60,6 +60,9 @@ function OptionsDlg::onWake( %this )
OP_ShadowSlider.setValue( $pref::Shadows );
OP_InteriorDetailSlider.setValue( $pref::Interior::detailAdjust );
OP_VisibleDistanceSlider.setValue( $pref::VisibleDistanceMod );
OP_ParticleDensitySlider.setValue( 4.0 - $pref::ParticleDensity );
OP_DynamicLightSlider.setValue( 100 - $pref::Interior::DynamicLightsClipPix );
updateDynamicLightSliderState();
OP_SkyDetailMenu.init();
if ( !$pref::SkyOn )
%selId = 5;
@ -514,6 +517,10 @@ function OptionsDlg::saveSettings( %this )
$pref::TS::screenError = $max_TSScreenError - mFloor( OP_ShapeSlider.getValue() * ( $max_TSScreenError - $min_TSScreenError ) );
$pref::TS::detailAdjust = $min_TSDetailAdjust + OP_ShapeSlider.getValue() * ( $max_TSDetailAdjust - $min_TSDetailAdjust );
$pref::Shadows = OP_ShadowSlider.getValue();
$pref::ParticleDensity = 4.0 - OP_ParticleDensitySlider.getValue();
%val = 100 - OP_DynamicLightSlider.getValue();
$pref::Interior::DynamicLightsClipPix = $pref::Terrain::DynamicLightsClipPix = %val;
$pref::Interior::DynamicLightsFadePix = $pref::Terrain::DynamicLightsFadePix = 2 * %val;
setShadowDetailLevel( $pref::Shadows );
$pref::Interior::detailAdjust = OP_InteriorDetailSlider.getValue();
$pref::VisibleDistanceMod = OP_VisibleDistanceSlider.getValue();
@ -836,6 +843,15 @@ function updateTerrainDetail()
OP_TerrainSlider.setValue( $max_screenerror - $pref::Terrain::screenError );
}
//------------------------------------------------------------------------------
function updateDynamicLightSliderState()
{
%on = $pref::Interior::DynamicLights || $pref::Terrain::dynamicLights;
OP_DynamicLightText.setVisible( %on );
OP_DynamicLightText_Disabled.setVisible( !%on );
OP_DynamicLightSlider.setActive( %on );
}
//------------------------------------------------------------------------------
function OP_SkyDetailMenu::init( %this )
{

View file

@ -81,6 +81,10 @@ function StaticShapeData::onEnabled(%data, %obj, %prevState)
{
if(%obj.waypoint)
game.switchWaypoint(%obj.waypoint);
if(%obj.isPowered())
%data.onGainPowerEnabled(%obj);
Parent::onEnabled(%data, %obj, %prevState);
}
};

View file

@ -22,6 +22,9 @@ function Observer::onTrigger(%data,%obj,%trigger,%state)
//trigger types: 0:fire 1:altTrigger 2:jump 3:jet 4:throw
%client = %obj.getControllingClient();
if (%client == 0)
return;
switch$ (%obj.mode)
{
case "justJoined":

View file

@ -653,7 +653,7 @@ datablock SimDataBlock(MediumPlayerDamageProfile)
damageScale[$DamageType::Bullet] = 1.0;
damageScale[$DamageType::ELF] = 0.75;
damageScale[$DamageType::ShockLance] = 1.0;
damageScale[$DamageType::Laser] = 1.2;
damageScale[$DamageType::Laser] = 1.1;
damageScale[$DamageType::ShrikeBlaster] = 1.0;
damageScale[$DamageType::BellyTurret] = 1.0;
damageScale[$DamageType::AATurret] = 0.7;
@ -686,7 +686,7 @@ datablock SimDataBlock(HeavyPlayerDamageProfile)
damageScale[$DamageType::Bullet] = 0.6;
damageScale[$DamageType::ELF] = 0.75;
damageScale[$DamageType::ShockLance] = 1.0;
damageScale[$DamageType::Laser] = 1.2;
damageScale[$DamageType::Laser] = 0.63;
damageScale[$DamageType::ShrikeBlaster] = 1.0;
damageScale[$DamageType::BellyTurret] = 1.0;
damageScale[$DamageType::AATurret] = 0.7;

View file

@ -33,6 +33,8 @@ function TCPDebugger::onLine(%this, %line)
%this.handleRunning();
else if(%cmd $= "EVALOUT")
%this.handleEvalOut(%rest);
else if(%cmd $= "OBJTAGLISTOUT")
%this.handleObjTagList(%rest);
else
%this.handleError(%line);
}
@ -168,6 +170,10 @@ function TCPDebugger::handleEvalOut(%this, %line)
}
}
function TCPDebugger::handleObjTagList(%this, %line)
{
}
function TCPDebugger::handleError(%this, %line)
{
DebuggerConsoleView.print("ERROR - bogus message: " @ %line);

View file

@ -2773,7 +2773,7 @@ function DefaultGame::voteChangeTimeLimit( %game, %admin, %newLimit )
%cause = "";
if ( %admin )
{
messageAll( 'AdminSetTimeLimit', '\c2The Admin changed the mission time limit to %1 minutes.', %newLimit );
messageAll( 'MsgAdminForce', '\c2The Admin changed the mission time limit to %1 minutes.', %newLimit );
$Host::TimeLimit = %newLimit;
%cause = "(admin)";
}

View file

@ -612,9 +612,9 @@ function InventoryDeployableImage::testInventoryTooClose(%item, %plyr)
return %turretInRange;
}
function TurretOutdoorDeployableImage::testTurretTooClose(%item, %plyr)
function TurretIndoorDeployableImage::testTurretTooClose(%item, %plyr)
{
InitContainerRadiusSearch(%item.surfacePt, $TurretOutdoorSpaceRadius, $TypeMasks::StaticShapeObjectType);
InitContainerRadiusSearch(%item.surfacePt, $TurretIndoorSpaceRadius, $TypeMasks::StaticShapeObjectType);
// old function was only checking whether the first object found was a turret -- also wasn't checking
// which team the object was on

View file

@ -242,6 +242,9 @@ function SimObject::incCatagory(%this)
function ShapeBase::setInventory(%this,%data,%value,%force)
{
if (!isObject(%data))
return;
%name = %data.getName();
if (%value < 0)
%value = 0;

View file

@ -595,6 +595,8 @@ datablock StaticShapeData(DeployedBeacon) : StaticShapeDamageProfile
beacon = true;
targetNameTag = 'beacon';
deployedObject = true;
dynamicType = $TypeMasks::SensorObjectType;
debrisShapeName = "debris_generic_small.dts";

View file

@ -1408,6 +1408,9 @@ datablock PlayerData(LightMaleHumanArmor) : LightPlayerDamageProfile
//max[Rock] = 1;
observeParameters = "0.5 4.5 4.5";
shieldEffectScale = "0.7 0.7 1.0";
};
@ -1663,6 +1666,8 @@ datablock PlayerData(MediumMaleHumanArmor) : MediumPlayerDamageProfile
//max[Rock] = 1;
observeParameters = "0.5 4.5 4.5";
shieldEffectScale = "0.7 0.7 1.0";
};
@ -1914,6 +1919,8 @@ datablock PlayerData(HeavyMaleHumanArmor) : HeavyPlayerDamageProfile
//max[Rock] = 1;
observeParameters = "0.5 4.5 4.5";
shieldEffectScale = "0.7 0.7 1.0";
};
@ -2535,7 +2542,7 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am
}
%targetClient = %targetObject.getOwnerClient();
%sourceClient = %sourceObject ? %sourceObject.getOwnerClient() : 0;
%sourceClient = isObject(%sourceObject) ? %sourceObject.getOwnerClient() : 0;
%targetTeam = %targetClient.team;
@ -2549,11 +2556,11 @@ function Armor::damageObject(%data, %targetObject, %sourceObject, %position, %am
else if(isObject(%sourceObject) && %sourceObject.getClassName() $= "Turret")
%sourceTeam = getTargetSensorGroup(%sourceObject.getTarget());
else if( isObject(%sourceObject) &&
( %sourceObject.getClassName() $= "FlyingVehicle" || %sourceObject.getClassName() $= "WheeledVehicle" ) || %sourceObject.getClassName() $= "HoverVehicle")
( %sourceObject.getClassName() $= "FlyingVehicle" || %sourceObject.getClassName() $= "WheeledVehicle" || %sourceObject.getClassName() $= "HoverVehicle"))
%sourceTeam = getTargetSensorGroup(%sourceObject.getTarget());
else
{
if (%sourceObject && %sourceObject.getTarget() >= 0 )
if (isObject(%sourceObject) && %sourceObject.getTarget() >= 0 )
{
%sourceTeam = getTargetSensorGroup(%sourceObject.getTarget());
}

View file

@ -41,21 +41,6 @@ function SniperProjectileData::onCollision(%data, %projectile, %targetObject, %m
%targetObject.damage(%projectile.sourceObject, %position, %modifier * %damageAmount, %data.directDamageType);
}
function TurretImageData::onFire( %data, %obj, %slot )
{
if( %data.muzzleFlash !$= "" )
{
%flash = new Shockwave()
{
dataBlock = %data.muzzleFlash;
pos = %obj.getMuzzlePoint(%slot);
normal = %obj.getMuzzleVector(%slot);
};
}
Parent::onFire( %data, %obj, %slot );
}
function ShapeBaseImageData::onFire(%data, %obj, %slot)
{
%data.lightStart = getSimTime();

View file

@ -73,6 +73,7 @@ function CreateServer(%mission, %missionType)
$missionSequence = 0;
$CurrentMissionType = %missionType;
$HostGameBotCount = 0;
$HostGamePlayerCount = 0;
if ( $HostGameType !$= "SinglePlayer" )
allowConnections(true);
@ -374,6 +375,10 @@ function GameConnection::onConnect( %client, %name, %raceGender, %skin, %voice,
case "Bioderm":
%client.sex = "Male";
%client.race = "Bioderm";
default:
error("Invalid race/gender combo passed: " @ %raceGender);
%client.sex = "Male";
%client.race = "Human";
}
%client.armor = "Light";

View file

@ -5,24 +5,24 @@
function StaticShapeData::onGainPowerEnabled(%data, %obj)
{
if(%data.ambientThreadPowered)
%obj.playThread($AmbientThread, "ambient");
// if it's a deployed object, schedule the power thread; else play it immediately
if(%data.deployAmbientThread)
%obj.schedule(750, "playThread", $PowerThread, "Power");
else
%obj.playThread($PowerThread,"Power");
// deployable objects get their recharge rate set right away -- don't set it again unless
// the object has just been re-enabled
if(%obj.initDeploy)
%obj.initDeploy = false;
else
{
if(%obj.getRechargeRate() <= 0)
{
%oldERate = %obj.getRechargeRate();
%obj.setRechargeRate(%oldERate + %data.rechargeRate);
}
}
%obj.playThread($AmbientThread, "ambient");
// if it's a deployed object, schedule the power thread; else play it immediately
if(%data.deployAmbientThread)
%obj.schedule(750, "playThread", $PowerThread, "Power");
else
%obj.playThread($PowerThread,"Power");
// deployable objects get their recharge rate set right away -- don't set it again unless
// the object has just been re-enabled
if(%obj.initDeploy)
%obj.initDeploy = false;
else
{
if(%obj.getRechargeRate() <= 0)
{
%oldERate = %obj.getRechargeRate();
%obj.setRechargeRate(%oldERate + %data.rechargeRate);
}
}
if(%data.humSound !$= "")
%obj.playAudio($HumSound, %data.humSound);
%obj.setPoweredState(true);
@ -36,13 +36,13 @@ function StaticShapeData::onLosePowerDisabled(%data, %obj)
if(%data.ambientThreadPowered)
%obj.pauseThread($AmbientThread);
if(!%data.alwaysAmbient)
{
%obj.stopThread($PowerThread);
// MES -- drop shields and stop them from regenerating after power loss
%obj.setRechargeRate(0.0);
%obj.setEnergyLevel(0.0);
}
if(!%data.alwaysAmbient)
{
%obj.stopThread($PowerThread);
// MES -- drop shields and stop them from regenerating after power loss
%obj.setRechargeRate(0.0);
%obj.setEnergyLevel(0.0);
}
if(%data.humSound !$= "")
%obj.stopAudio($HumSound);
%obj.setPoweredState(false);
@ -132,7 +132,7 @@ datablock ExplosionData(ShapeExplosion)
datablock StaticShapeData(HeavyMaleHuman_Dead)
{
className = "deadArmor";
className = "deadArmor";
catagory = "Player Armors";
shapeFile = "heavy_male_dead.dts";
isInvincible = true;
@ -140,7 +140,7 @@ datablock StaticShapeData(HeavyMaleHuman_Dead)
datablock StaticShapeData(MediumMaleHuman_Dead)
{
className = "deadArmor";
className = "deadArmor";
catagory = "Player Armors";
shapeFile = "medium_male_dead.dts";
isInvincible = true;
@ -148,7 +148,7 @@ datablock StaticShapeData(MediumMaleHuman_Dead)
datablock StaticShapeData(LightMaleHuman_Dead)
{
className = "deadArmor";
className = "deadArmor";
catagory = "Player Armors";
shapeFile = "light_male_dead.dts";
isInvincible = true;
@ -160,7 +160,7 @@ function deadArmor::onAdd(%data, %obj)
}
//*****************************************************************************
//* Flagstands - Data Blocks
//* Flagstands - Data Blocks
//*****************************************************************************
datablock StaticShapeData(InteriorFlagStand)
{
@ -189,29 +189,29 @@ datablock StaticShapeData(ExteriorFlagStand)
function ExteriorFlagStand::onAdd(%this, %obj)
{
Parent::onAdd(%this, %obj);
%obj.playThread($ActivateThread, "activate");
%obj.playThread($ActivateThread, "activate");
}
function ExteriorFlagStand::onFlagTaken(%this, %obj)
{
%obj.setThreadDir($ActivateThread, 0);
%obj.setThreadDir($ActivateThread, 0);
}
function ExteriorFlagStand::onFlagReturn(%this, %obj)
{
%obj.setThreadDir($ActivateThread, 1);
%obj.setThreadDir($ActivateThread, 1);
}
function ExteriorFlagStand::onCollision(%this, %obj, %colObj)
{
game.flagStandCollision(%this, %obj, %colObj);
game.flagStandCollision(%this, %obj, %colObj);
}
function InteriorFlagStand::onCollision(%this, %obj, %colObj)
{
game.flagStandCollision(%this, %obj, %colObj);
game.flagStandCollision(%this, %obj, %colObj);
}
///////////////////////////////////////////////
//end flag stand functions
///////////////////////////////////////////////
@ -226,7 +226,7 @@ datablock StaticShapeData(FlipFlop)
cmdIcon = "CMDSwitchIcon";
cmdMiniIconName = "commander/MiniIcons/com_switch_grey";
targetTypeTag = 'Switch';
alwaysAmbient = true;
alwaysAmbient = true;
needsNoPower = true;
emap = true;
};
@ -251,13 +251,13 @@ function FlipFlop::playerTouch(%data,%obj,%col)
function randomOrg(%organicName, %num, %radius)
{
%SPACING = 1.0; //meters between center of organic and another object
%SPACING = 1.0; //meters between center of organic and another object
//return help info
if(%organicName $="" || !%num || !%radius) {
echo("randomOrg(<shape name>, <quantity>, <radius of grove desired>);");
return;
}
//return help info
if(%organicName $="" || !%num || !%radius) {
echo("randomOrg(<shape name>, <quantity>, <radius of grove desired>);");
return;
}
%organicIndex = -1;
for (%i = 0; %i < $NumAStaticTSObjects; %i++) {
@ -287,131 +287,131 @@ function randomOrg(%organicName, %num, %radius)
%minScale = getWord($StaticTSObjects[%organicIndex], 6);
%maxScale = getWord($StaticTSObjects[%organicIndex], 7);
//set up folders in mis file
$RandomOrganicsAdded++; //to keep track of groups
if(!isObject(RandomOrganics)) {
%randomOrgGroup = new simGroup(RandomOrganics);
MissionGroup.add(%randomOrgGroup);
}
%groupName = "Addition"@$RandomOrganicsAdded@%organicName;
%group = new simGroup(%groupName);
RandomOrganics.add(%group);
%ctr = LocalClientConnection.camera.getPosition();
%areaX = getWord(%ctr, 0) - %radius;
%areaY = getWord(%ctr, 1) - %radius;
%orgCount = %num;
while((%orgCount > 0) && (%retries < (15000 / %maxSlope))) //theoretically, a thorough number of retries
{
//find a tile
%x = (getRandom(mFloor(%areaX / 8), mFloor((%areaX + (%radius * 2)) / 8)) * 8) + 4; //tile center
%y = (getRandom(mFloor(%areaY / 8), mFloor((%areaY + (%radius * 2)) / 8)) * 8) + 4;
//set up folders in mis file
$RandomOrganicsAdded++; //to keep track of groups
if(!isObject(RandomOrganics)) {
%randomOrgGroup = new simGroup(RandomOrganics);
MissionGroup.add(%randomOrgGroup);
}
%groupName = "Addition"@$RandomOrganicsAdded@%organicName;
%group = new simGroup(%groupName);
RandomOrganics.add(%group);
%ctr = LocalClientConnection.camera.getPosition();
%areaX = getWord(%ctr, 0) - %radius;
%areaY = getWord(%ctr, 1) - %radius;
%orgCount = %num;
while((%orgCount > 0) && (%retries < (15000 / %maxSlope))) //theoretically, a thorough number of retries
{
//find a tile
%x = (getRandom(mFloor(%areaX / 8), mFloor((%areaX + (%radius * 2)) / 8)) * 8) + 4; //tile center
%y = (getRandom(mFloor(%areaY / 8), mFloor((%areaY + (%radius * 2)) / 8)) * 8) + 4;
%start = %x @ " " @ %y @ " 2000";
%end = %x @ " " @ %y @ " -1";
%ground = containerRayCast(%start, %end, $TypeMasks::TerrainObjectType, 0);
%z = getWord(%ground, 3);
%z += %zOffset;
%position = %x @ " " @ %y @ " " @ %z;
%start = %x @ " " @ %y @ " 2000";
%end = %x @ " " @ %y @ " -1";
%ground = containerRayCast(%start, %end, $TypeMasks::TerrainObjectType, 0);
%z = getWord(%ground, 3);
%z += %zOffset;
%position = %x @ " " @ %y @ " " @ %z;
// get normal from both sides of the square
%start = %x + 2 @ " " @ %y @ " 2000";
%end = %x + 2 @ " " @ %y @ " -1";
%hit1 = containerRayCast(%start, %end, $TypeMasks::TerrainObjectType, 0);
%start = %x - 2 @ " " @ %y @ " 2000";
%end = %x - 2 @ " " @ %y @ " -1";
%hit2 = containerRayCast(%start, %end, $TypeMasks::TerrainObjectType, 0);
// get normal from both sides of the square
%start = %x + 2 @ " " @ %y @ " 2000";
%end = %x + 2 @ " " @ %y @ " -1";
%hit1 = containerRayCast(%start, %end, $TypeMasks::TerrainObjectType, 0);
%start = %x - 2 @ " " @ %y @ " 2000";
%end = %x - 2 @ " " @ %y @ " -1";
%hit2 = containerRayCast(%start, %end, $TypeMasks::TerrainObjectType, 0);
%norm1 = getWord(%hit1, 4) @ " " @ getWord(%hit1, 5) @ " " @ getWord(%hit1, 6);
%norm2 = getWord(%hit2, 4) @ " " @ getWord(%hit2, 5) @ " " @ getWord(%hit2, 6);
%norm1 = getWord(%hit1, 4) @ " " @ getWord(%hit1, 5) @ " " @ getWord(%hit1, 6);
%norm2 = getWord(%hit2, 4) @ " " @ getWord(%hit2, 5) @ " " @ getWord(%hit2, 6);
//if either side of tile has greater slope than allowed, move on.
%angNorm1 = getTerrainAngle(%norm1);
%angNorm2 = getTerrainAngle(%norm2);
if ((getTerrainAngle(%norm1) > %maxSlope) || (getTerrainAngle(%norm2) > %maxslope))
{
%retries++;
continue;
}
//if either side of tile has greater slope than allowed, move on.
%angNorm1 = getTerrainAngle(%norm1);
%angNorm2 = getTerrainAngle(%norm2);
if ((getTerrainAngle(%norm1) > %maxSlope) || (getTerrainAngle(%norm2) > %maxslope))
{
%retries++;
continue;
}
%terrainNormal = VectorAdd(%norm1, %norm2);
%terrainNormal = VectorNormalize(%terrainNormal);
//search surroundings for obstacles. If obstructed, move on.
InitContainerRadiusSearch(%position, %spacing, $TypeMasks::VehicleObjectType |
$TypeMasks::MoveableObjectType |
$TypeMasks::StaticShapeObjectType |
$TypeMasks::TSStaticShapeObjectType |
$TypeMasks::ForceFieldObjectType |
$TypeMasks::TurretObjectType |
$TypeMasks::InteriorObjectType |
$TypeMasks::ItemObjectType);
%this = containerSearchNext();
if(%this)
{
%retries++;
continue;
}
//rotate it
if(%slopeWithTerrain)
{
%rotAxis = vectorCross(%terrainNormal, "0 0 1");
%rotAxis = vectorNormalize(%rotAxis);
%rotation = %rotAxis @ " " @ getTerrainAngle(%terrainNormal);
}
else %rotation = "1 0 0 0";
%randomAngle = getRandom(360);
%zrot = MatrixCreate("0 0 0", "0 0 1 " @ %randomAngle);
%orient = MatrixCreate(%position, %rotation);
%finalXForm = MatrixMultiply(%orient, %zrot);
%terrainNormal = VectorAdd(%norm1, %norm2);
%terrainNormal = VectorNormalize(%terrainNormal);
//search surroundings for obstacles. If obstructed, move on.
InitContainerRadiusSearch(%position, %spacing, $TypeMasks::VehicleObjectType |
$TypeMasks::MoveableObjectType |
$TypeMasks::StaticShapeObjectType |
$TypeMasks::TSStaticShapeObjectType |
$TypeMasks::ForceFieldObjectType |
$TypeMasks::TurretObjectType |
$TypeMasks::InteriorObjectType |
$TypeMasks::ItemObjectType);
%this = containerSearchNext();
if(%this)
{
%retries++;
continue;
}
//rotate it
if(%slopeWithTerrain)
{
%rotAxis = vectorCross(%terrainNormal, "0 0 1");
%rotAxis = vectorNormalize(%rotAxis);
%rotation = %rotAxis @ " " @ getTerrainAngle(%terrainNormal);
}
else %rotation = "1 0 0 0";
%randomAngle = getRandom(360);
%zrot = MatrixCreate("0 0 0", "0 0 1 " @ %randomAngle);
%orient = MatrixCreate(%position, %rotation);
%finalXForm = MatrixMultiply(%orient, %zrot);
//scale it
%scaleMin = 8; //default min
%scaleMax = 14; //default max
if(%minScale)
%scaleMin = %minScale * 10;
if(%maxScale)
%scaleMax = %maxScale * 10;
%scaleInt = getRandom(%scaleMin, %scaleMax);
%scale = %scaleInt/10;
%evenScale = %scale SPC %scale SPC %scale;
//scale it
%scaleMin = 8; //default min
%scaleMax = 14; //default max
if(%minScale)
%scaleMin = %minScale * 10;
if(%maxScale)
%scaleMax = %maxScale * 10;
%scaleInt = getRandom(%scaleMin, %scaleMax);
%scale = %scaleInt/10;
%evenScale = %scale SPC %scale SPC %scale;
//create it
%position = %x SPC %y SPC (%z += %zoffset);
%newOrganic = new TSStatic() {
position = %position;
rotation = %rotation;
scale = %evenScale;
shapeName = %shapeFileName;
};
%group.add(%newOrganic);
%newOrganic.setTransform(%finalXForm);
//create it
%position = %x SPC %y SPC (%z += %zoffset);
%newOrganic = new TSStatic() {
position = %position;
rotation = %rotation;
scale = %evenScale;
shapeName = %shapeFileName;
};
%group.add(%newOrganic);
%newOrganic.setTransform(%finalXForm);
%orgCount--; //dec number of shapes left to place
%retries = 0; //reset retry counter
}
if (%orgCount > 0)
{
error("Unable to place all shapes, area saturated.");
error("Looking for clear area " @ (%spacing * 2) @ " meters in diameter, with a max slope of " @ %maxSlope);
}
echo("Placed " @ %num - %orgCount @ " of " @ %num);
%orgCount--; //dec number of shapes left to place
%retries = 0; //reset retry counter
}
if (%orgCount > 0)
{
error("Unable to place all shapes, area saturated.");
error("Looking for clear area " @ (%spacing * 2) @ " meters in diameter, with a max slope of " @ %maxSlope);
}
echo("Placed " @ %num - %orgCount @ " of " @ %num);
}
function getTerrainAngle(%point)
{
%up = "0 0 1";
%angleRad = mACos(vectorDot(%point, %up));
%angleDeg = mRadToDeg(%angleRad);
//echo("angle is "@%angleDeg);
return %angleDeg;
%up = "0 0 1";
%angleRad = mACos(vectorDot(%point, %up));
%angleDeg = mRadToDeg(%angleRad);
//echo("angle is "@%angleDeg);
return %angleDeg;
}
@ -494,22 +494,22 @@ datablock SensorData(SensorLgPulseObj)
datablock StaticShapeData(SensorLargePulse) : StaticShapeDamageProfile
{
className = Sensor;
className = Sensor;
catagory = "Sensors";
shapeFile = "sensor_pulse_large.dts";
maxDamage = 1.5;
destroyedLevel = 1.5;
disabledLevel = 0.85;
explosion = ShapeExplosion;
expDmgRadius = 10.0;
expDamage = 0.5;
expImpulse = 2000.0;
expDmgRadius = 10.0;
expDamage = 0.5;
expImpulse = 2000.0;
dynamicType = $TypeMasks::SensorObjectType;
isShielded = true;
energyPerDamagePoint = 33;
maxEnergy = 110;
rechargeRate = 0.31;
isShielded = true;
energyPerDamagePoint = 33;
maxEnergy = 110;
rechargeRate = 0.31;
ambientThreadPowered = true;
humSound = SensorHumSound;
@ -539,22 +539,22 @@ datablock SensorData(SensorMedPulseObj)
datablock StaticShapeData(SensorMediumPulse) : StaticShapeDamageProfile
{
className = Sensor;
className = Sensor;
catagory = "Sensors";
shapeFile = "sensor_pulse_medium.dts";
maxDamage = 1.2;
destroyedLevel = 1.2;
disabledLevel = 0.68;
explosion = ShapeExplosion;
expDmgRadius = 7.0;
expDamage = 0.4;
expImpulse = 1500;
expDmgRadius = 7.0;
expDamage = 0.4;
expImpulse = 1500;
dynamicType = $TypeMasks::SensorObjectType;
isShielded = true;
energyPerDamagePoint = 33;
maxEnergy = 90;
rechargeRate = 0.31;
isShielded = true;
energyPerDamagePoint = 33;
maxEnergy = 90;
rechargeRate = 0.31;
ambientThreadPowered = true;
humSound = SensorHumSound;
@ -604,16 +604,16 @@ datablock StaticShapeData(GeneratorLarge) : StaticShapeDamageProfile
maxDamage = 1.50;
destroyedLevel = 1.50;
disabledLevel = 0.85;
expDmgRadius = 10.0;
expDamage = 0.5;
expImpulse = 1500.0;
expDmgRadius = 10.0;
expDamage = 0.5;
expImpulse = 1500.0;
noIndividualDamage = true; //flag to make these invulnerable for certain mission types
dynamicType = $TypeMasks::GeneratorObjectType;
isShielded = true;
energyPerDamagePoint = 30;
maxEnergy = 50;
rechargeRate = 0.05;
isShielded = true;
energyPerDamagePoint = 30;
maxEnergy = 50;
rechargeRate = 0.05;
humSound = GeneratorHumSound;
cmdCategory = "Support";
@ -634,18 +634,18 @@ datablock StaticShapeData(SolarPanel) : StaticShapeDamageProfile
maxDamage = 1.00;
destroyedLevel = 1.00;
disabledLevel = 0.55;
expDmgRadius = 5.0;
expDamage = 0.3;
expImpulse = 1000.0;
expDmgRadius = 5.0;
expDamage = 0.3;
expImpulse = 1000.0;
noIndividualDamage = true; //flag to make these invulnerable for certain mission types
emap = true;
isShielded = true;
energyPerDamagePoint = 30;
rechargeRate = 0.05;
rechargeRate = 0.05;
dynamicType = $TypeMasks::GeneratorObjectType;
maxEnergy = 30;
maxEnergy = 30;
humSound = GeneratorHumSound;
cmdCategory = "Support";
@ -667,7 +667,7 @@ function Generator::onEnabled(%data, %obj, %prevState)
{
%obj.incPowerCount();
Parent::onEnabled(%data, %obj, %prevState);
}
}
//******************************************************************************
//Nexus Effect (Hunters)
@ -735,7 +735,7 @@ function ShapeBaseData::onDestroyed(%data, %obj, %prevState)
function ShapeBaseData::checkShields(%data, %targetObject, %position, %amount, %damageType)
{
%energy = %targetObject.getEnergyLevel();
%energy = %targetObject.getEnergyLevel();
%strength = %energy / %data.energyPerDamagePoint;
%shieldScale = %data.shieldDamageScale[%damageType];
if(%shieldScale $= "")
@ -759,20 +759,20 @@ function ShapeBaseData::checkShields(%data, %targetObject, %position, %amount, %
function StaticShapeData::damageObject(%data, %targetObject, %sourceObject, %position, %amount, %damageType)
{
// if this is a non-team mission type and the object is "protected", don't damage it
if(%data.noIndividualDamage && Game.allowsProtectedStatics())
return;
// if this is a non-team mission type and the object is "protected", don't damage it
if(%data.noIndividualDamage && Game.allowsProtectedStatics())
return;
// if this is a Siege mission and this object shouldn't take damage (e.g. vehicle stations)
if(%data.noDamageInSiege && Game.class $= "SiegeGame")
return;
// if this is a Siege mission and this object shouldn't take damage (e.g. vehicle stations)
if(%data.noDamageInSiege && Game.class $= "SiegeGame")
return;
if(%sourceObject)
{
%targetObject.lastDamagedBy = %sourceObject.client;
%targetObject.lastDamagedByTeam = %sourceObject.client.team;
%targetObject.damageTimeMS = GetSimTime();
}
if(%sourceObject)
{
%targetObject.lastDamagedBy = %sourceObject.client;
%targetObject.lastDamagedByTeam = %sourceObject.client.team;
%targetObject.damageTimeMS = GetSimTime();
}
// Scale damage type & include shield calculations...
if (%data.isShielded)
@ -780,27 +780,27 @@ function StaticShapeData::damageObject(%data, %targetObject, %sourceObject, %pos
%damageScale = %data.damageScale[%damageType];
if(%damageScale !$= "")
%amount *= %damageScale;
%amount *= %damageScale;
//if team damage is off, cap the amount of damage so as not to disable the object...
if (!$TeamDamage && !%targetObject.getDataBlock().deployedObject && %targetObject.getDataBlock.getName $= "DeployedBeacon")
{
//see if the object is being shot by a friendly
%srcClient = %sourceObject.client;
if (isObject(%srcClient))
{
if (isTargetFriendly(%targetObject.getTarget() , %srcClient.getSensorGroup()))
{
%curDamage = %targetObject.getDamageLevel();
%availableDamage = %targetObject.getDataBlock().disabledLevel - %curDamage - 0.05;
if (%amount > %availableDamage)
%amount = %availableDamage;
}
}
}
//if team damage is off, cap the amount of damage so as not to disable the object...
if (!$TeamDamage && !%targetObject.getDataBlock().deployedObject)
{
//see if the object is being shot by a friendly
%srcClient = %sourceObject.client;
if (isObject(%srcClient))
{
if (isTargetFriendly(%targetObject.getTarget() , %srcClient.getSensorGroup()))
{
%curDamage = %targetObject.getDamageLevel();
%availableDamage = %targetObject.getDataBlock().disabledLevel - %curDamage - 0.05;
if (%amount > %availableDamage)
%amount = %availableDamage;
}
}
}
// if there's still damage to apply
if (%amount > 0)
// if there's still damage to apply
if (%amount > 0)
%targetObject.applyDamage(%amount);
}
@ -809,27 +809,28 @@ function StaticShapeData::onDamage(%this,%obj)
// Set damage state based on current damage level
%damage = %obj.getDamageLevel();
if(%damage >= %this.destroyedLevel)
{
if(%obj.getDamageState() !$= "Destroyed")
{
%obj.setDamageState(Destroyed);
// if object has an explosion damage radius associated with it, apply explosion damage
if(%this.expDmgRadius)
RadiusExplosion(%obj, %obj.getWorldBoxCenter(), %this.expDmgRadius, %this.expDamage, %this.expImpulse, %obj, $DamageType::Explosion);
}
}
{
if(%obj.getDamageState() !$= "Destroyed")
{
%obj.setDamageState(Destroyed);
// if object has an explosion damage radius associated with it, apply explosion damage
if(%this.expDmgRadius)
RadiusExplosion(%obj, %obj.getWorldBoxCenter(), %this.expDmgRadius, %this.expDamage, %this.expImpulse, %obj, $DamageType::Explosion);
}
}
else
{
if(%damage >= %this.disabledLevel)
{
if(%obj.getDamageState() !$= "Disabled")
%obj.setDamageState(Disabled);
}
{
if(%obj.getDamageState() !$= "Disabled")
%obj.setDamageState(Disabled);
}
else
{
if(%obj.getDamageState() !$= "Enabled")
%obj.setDamageState(Enabled);
}
{
if(%obj.getDamageState() !$= "Enabled")
%obj.setDamageState(Enabled);
}
}
}
// --------------------------------------------------------------------
@ -837,66 +838,66 @@ function StaticShapeData::onDamage(%this,%obj)
datablock StaticShapeData(StormLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_storm.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(InfernoLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_inf.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(BiodermLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_bd.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(BloodEagleLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_be.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(DSwordLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_ds.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(HarbingerLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_hb.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(StarwolfLogo)
{
className = Logo;
className = Logo;
shapeFile = "teamlogo_sw.dts";
alwaysAmbient = true;
alwaysAmbient = true;
};
datablock StaticShapeData(LogoProjector)
{
className = Projector;
className = Projector;
catagory = "Objectives";
shapeFile = "teamlogo_projector.dts";
alwaysAmbient = true;
alwaysAmbient = true;
isInvincible = true;
};
function Projector::onAdd(%data, %obj)
{
Parent::onAdd(%data, %obj);
%obj.holo = 0;
%obj.holo = 0;
}
////////////////////////////////////////////
@ -1034,5 +1035,5 @@ function TSStatic::create(%shapeName)
function TSStatic::damage(%this)
{
// prevent console error spam
// prevent console error spam
}

View file

@ -113,6 +113,8 @@ datablock TurretData(TurretDeployedWallIndoor) : TurretDamageProfile
thetaMax = 145;
thetaNull = 90;
deployedObject = true;
primaryAxis = yaxis;
isShielded = true;
@ -157,6 +159,8 @@ datablock TurretData(TurretDeployedCeilingIndoor) : TurretDamageProfile
thetaNull = 90;
heatSignature = 0.0;
deployedObject = true;
primaryAxis = revzaxis;
isShielded = true;
@ -262,6 +266,7 @@ datablock TurretImageData(DeployableIndoorBarrel)
stateTransitionOnTimeout[3] = "Reload";
stateTimeoutValue[3] = 0.3;
stateFire[3] = true;
stateShockwave[3] = true;
stateRecoil[3] = LightRecoil;
stateAllowImageChange[3] = false;
stateSequence[3] = "Fire";

View file

@ -198,6 +198,7 @@ datablock TurretImageData(DeployableOutdoorBarrel)
stateTransitionOnTimeout[3] = "Reload";
stateTimeoutValue[3] = 0.3;
stateFire[3] = true;
stateShockwave[3] = true;
stateRecoil[3] = LightRecoil;
stateAllowImageChange[3] = false;
stateSequence[3] = "Fire";

View file

@ -236,7 +236,7 @@ function VehicleData::onDestroyed(%data, %obj, %prevState)
%flingee.damage(0, %obj.getPosition(), 0.4, $DamageType::Explosion);
}
}
%obj.schedule(600, "delete");
%obj.schedule(2000, "delete");
}
function radiusVehicleExplosion(%data, %vehicle)
@ -419,7 +419,8 @@ function MobileBaseVehicle::onAdd(%this, %obj)
Parent::onAdd(%this, %obj);
%obj.station = "";
%obj.turret = "";
%obj.beacon = "";
%obj.schedule(5000, "playThread", $AmbientThread, "ambient");
}
@ -502,6 +503,10 @@ function MobileBaseVehicle::deleteAllMounted(%data, %obj)
%obj.teleporter.playThread($ActivateThread,"activate");
%obj.teleporter.playAudio($ActivateSound, StationTeleportDeacitvateSound);
}
if(isObject(%obj.beacon))
{
%obj.beacon.delete();
}
}
//**************************************************************
@ -754,6 +759,15 @@ function MobileBaseVehicle::vehicleDeploy(%data, %obj, %player, %force)
%obj.turret.setSelfPowered();
%obj.turret.playThread($PowerThread,"Power");
%obj.turret.mountImage(MissileBarrelLarge, 0 ,false);
%obj.beacon = new ScopeAlwaysShape() {
dataBlock = "DeployedBeacon";
position = %obj.position;
rotation = %obj.rotation;
team = %obj.team;
};
%obj.beacon.setBeaconType(friend);
%obj.beacon.setTarget(%obj.team);
checkSpawnPos(%obj, 20);
}
@ -814,6 +828,8 @@ function MobileBaseVehicle::onEndSequence(%data, %obj, %thread)
%obj.station.trigger.delete();
%obj.station.delete();
%obj.station = "";
%obj.beacon.delete();
%obj.unmountObject(%obj.turret);
%obj.turret.delete();
@ -1101,8 +1117,11 @@ function VehicleData::damageObject(%data, %targetObject, %sourceObject, %positio
if(%amount != 0)
%targetObject.applyDamage(%amount);
if(%targetObject.getDamageState() $= "Destroyed" && %momVec !$= "")
%targetObject.setMomentumVector(%momVec);
if(%targetObject.getDamageState() $= "Destroyed" )
{
if( %momVec !$= "")
%targetObject.setMomentumVector(%momVec);
}
}
function VehicleData::onImpact(%data, %vehicleObject, %collidedObject, %vec, %vecLen)

View file

@ -114,6 +114,7 @@ datablock FlyingVehicleData(BomberFlyer) : BomberDamageProfile
debrisShapeName = "vehicle_air_bomber_debris.dts";
debris = ShapeDebris;
renderWhenDestroyed = false;
drag = 0.2;
density = 1.0;
@ -239,6 +240,8 @@ datablock FlyingVehicleData(BomberFlyer) : BomberDamageProfile
checkRadius = 7.1895;
observeParameters = "1 10 10";
shieldEffectScale = "0.75 0.975 0.375";
};
//**************************************************************

View file

@ -24,6 +24,7 @@ datablock AudioProfile(HAPCFlyerThrustSound)
datablock FlyingVehicleData(HAPCFlyer) : HavocDamageProfile
{
spawnOffset = "0 0 6";
renderWhenDestroyed = false;
catagory = "Vehicles";
shapeFile = "vehicle_air_hapc.dts";
@ -161,6 +162,8 @@ datablock FlyingVehicleData(HAPCFlyer) : HavocDamageProfile
stuckTimerTicks = 32; // If the hapc spends more than 1 sec in contact with something
stuckTimerAngle = 80; // with a > 80 deg. pitch, BOOM!
shieldEffectScale = "1.0 0.9375 0.45";
};
function HAPCFlyer::hasDismountOverrides(%data, %obj)

View file

@ -61,6 +61,27 @@ datablock AudioProfile(MobileBaseStationUndeploySound)
preload = true;
};
//**************************************************************
// LIGHTS
//**************************************************************
datablock RunningLightData(MPBLight1)
{
pointSize = 3.0;
pointColor = "1.0 1.0 1.0 0.3";
pointNodeName = "Headlight_node01";
texture = "special/expFlare";
};
datablock RunningLightData(MPBLight2)
{
pointSize = 3.0;
pointColor = "1.0 1.0 1.0 0.3";
pointNodeName = "Headlight_node02";
texture = "special/expFlare";
};
//**************************************************************
// VEHICLE CHARACTERISTICS
//**************************************************************
@ -75,6 +96,7 @@ datablock SensorData(MPBDeployedSensor) : VehiclePulseSensor
datablock WheeledVehicleData(MobileBaseVehicle) : MPBDamageProfile
{
spawnOffset = "0 0 1.0";
renderWhenDestroyed = false;
catagory = "Vehicles";
shapeFile = "vehicle_land_mpbase.dts";
@ -211,6 +233,11 @@ datablock WheeledVehicleData(MobileBaseVehicle) : MPBDamageProfile
checkRadius = 7.5225;
observeParameters = "1 12 12";
runningLight[0] = MPBLight1;
runningLight[1] = MPBLight2;
shieldEffectScale = "0.85 1.2 0.7";
};
//**************************************************************

View file

@ -40,6 +40,29 @@ datablock AudioProfile(ShrikeBlasterDryFireSound)
preload = true;
};
//**************************************************************
// LIGHTS
//**************************************************************
datablock RunningLightData(ShrikeLight1)
{
type = 1;
radius = 2.0;
length = 3.0;
color = "1.0 1.0 1.0 1.0";
direction = "0.0 1.0 -1.0 ";
offset = "0.0 0.0 -0.5";
texture = "special/lightcone04";
};
datablock RunningLightData(ShrikeLight2)
{
radius = 1.5;
color = "1.0 1.0 1.0 0.3";
direction = "0.0 0.0 -1.0";
offset = "0.0 0.8 -1.2";
texture = "special/headlight4";
};
//**************************************************************
// VEHICLE CHARACTERISTICS
//**************************************************************
@ -55,6 +78,7 @@ datablock FlyingVehicleData(ScoutFlyer) : ShrikeDamageProfile
debrisShapeName = "vehicle_air_scout_debris.dts";
debris = ShapeDebris;
renderWhenDestroyed = false;
drag = 0.15;
density = 1.0;
@ -175,6 +199,12 @@ datablock FlyingVehicleData(ScoutFlyer) : ShrikeDamageProfile
checkRadius = 5.5;
observeParameters = "1 10 10";
runningLight[0] = ShrikeLight1;
// runningLight[1] = ShrikeLight2;
shieldEffectScale = "0.937 1.125 0.60";
};
//**************************************************************

View file

@ -96,6 +96,45 @@ datablock AudioProfile(AssaultMortarIdleSound)
preload = true;
};
//**************************************************************
// LIGHTS
//**************************************************************
datablock RunningLightData(TankLight1)
{
radius = 1.5;
color = "1.0 1.0 1.0 0.2";
nodeName = "Headlight_node01";
direction = "0.0 1.0 0.0";
texture = "special/headlight4";
};
datablock RunningLightData(TankLight2)
{
radius = 1.5;
color = "1.0 1.0 1.0 0.2";
nodeName = "Headlight_node02";
direction = "0.0 1.0 0.0";
texture = "special/headlight4";
};
datablock RunningLightData(TankLight3)
{
radius = 1.5;
color = "1.0 1.0 1.0 0.2";
nodeName = "Headlight_node03";
direction = "0.0 1.0 0.0";
texture = "special/headlight4";
};
datablock RunningLightData(TankLight4)
{
radius = 1.5;
color = "1.0 1.0 1.0 0.2";
nodeName = "Headlight_node04";
direction = "0.0 1.0 0.0";
texture = "special/headlight4";
};
//**************************************************************
// VEHICLE CHARACTERISTICS
//**************************************************************
@ -110,6 +149,7 @@ datablock HoverVehicleData(AssaultVehicle) : TankDamageProfile
shapeFile = "vehicle_grav_tank.dts";
multipassenger = true;
computeCRC = true;
renderWhenDestroyed = false;
weaponNode = 1;
@ -241,6 +281,13 @@ datablock HoverVehicleData(AssaultVehicle) : TankDamageProfile
checkRadius = 5.5535;
observeParameters = "1 10 10";
runningLight[0] = TankLight1;
runningLight[1] = TankLight2;
runningLight[2] = TankLight3;
runningLight[3] = TankLight4;
shieldEffectScale = "0.9 1.0 0.6";
};
//**************************************************************

View file

@ -27,6 +27,37 @@ datablock AudioProfile(ScoutThrustSound)
preload = true;
};
//**************************************************************
// LIGHTS
//**************************************************************
datablock RunningLightData(WildcatLight1)
{
radius = 1.0;
color = "1.0 1.0 1.0 0.3";
nodeName = "Headlight_node01";
direction = "-1.0 1.0 0.0";
texture = "special/headlight4";
};
datablock RunningLightData(WildcatLight2)
{
radius = 1.0;
color = "1.0 1.0 1.0 0.3";
nodeName = "Headlight_node02";
direction = "1.0 1.0 0.0";
texture = "special/headlight4";
};
datablock RunningLightData(WildcatLight3)
{
type = 2;
radius = 100.0;
color = "1.0 1.0 1.0 1.0";
offset = "0.0 0.0 0.0";
direction = "0.0 1.0 0.0";
texture = "special/projheadlight";
};
//**************************************************************
// VEHICLE CHARACTERISTICS
//**************************************************************
@ -43,6 +74,7 @@ datablock HoverVehicleData(ScoutVehicle) : WildcatDamageProfile
debrisShapeName = "vehicle_grav_scout_debris.dts";
debris = ShapeDebris;
renderWhenDestroyed = false;
drag = 0.0;
density = 0.9;
@ -161,6 +193,12 @@ datablock HoverVehicleData(ScoutVehicle) : WildcatDamageProfile
checkRadius = 1.7785;
observeParameters = "1 10 10";
runningLight[0] = WildcatLight1;
runningLight[1] = WildcatLight2;
runningLight[2] = WildcatLight3;
shieldEffectScale = "0.9375 1.125 0.6";
};
//**************************************************************

View file

@ -202,7 +202,7 @@ function EditDescriptionApply()
//-----------------------------------------------------------------------------
function GetProfileHdr(%type, %line)
{
%CRec = wonGetAuthInfo();
$GuidTribes = getRecords(wonGetAuthInfo(),1);
if(%type==0)
{
TProfileHdr.tribeID = getField(%line,0);
@ -216,23 +216,28 @@ function GetProfileHdr(%type, %line)
TL_Profile.setVisible(1);
TL_Roster.setVisible(1);
TL_News.setVisible(1);
for(%checkID=0;%checkID<getField(getRecord($GuidTribes,0),0);%checkID++)
{
if(getField(getRecord($GuidTribes,1+%checkID),3) == 1401)
TProfileHdr.twa = 4;
else if(TProfileHdr.tribe_id == getField(getRecord($GuidTribes,1+%checkID),3))
else
if(TProfileHdr.tribeid == getField(getRecord($GuidTribes,1+%checkID),3))
if(TProfileHdr.twa == 0)
TProfileHdr.twa = getField(getRecord($GuidTribes,1+%checkID),4);
}
TL_News.setVisible(TProfileHdr.twa);
TL_Invites.setVisible(TProfileHdr.twa);
if(TProfileHdr.twa > 1)
{
TW_Admin.setVisible(1);
TL_Invites.setVisible(1);
}
else
{
TW_Admin.setVisible(0);
TL_Invites.setVisible(0);
}
}
else
{
@ -792,16 +797,35 @@ function BrowserSearchDlg::onWake( %this )
BSearchOKBtn.setActive( false );
}
//-----------------------------------------------------------------------------
function BrowserSearchPane::GetOnlineStatus(%this)
{
%this.key = LaunchGui.key++;
%this.status = "getOnline";
for(%oStat=0;%oStat<BrowserSearchMatchList.RowCount();%oStat++)
{
if(%oStat == 0)
%roster = getField(BrowserSearchMatchList.getRowText(%oStat),3);
else
%roster = %roster TAB getField(BrowserSearchMatchList.getRowText(%oStat),3);
}
databaseQuery(69,%roster,%this,%this.key);
}
//-----------------------------------------------------------------------------
function BrowserSearchMatchList::onSelect( %this, %id, %text )
{
BSearchOKBtn.setActive( true );
}
//-----------------------------------------------------------------------------
function BrowserSearchMatchList::onAdd(%this)
{
BrowserSearchMatchList.addStyle( 1, "Univers", 12 , "150 150 150", "200 200 200", "60 60 60" );
}
//==-- BrowserSearchPane ----------------------------------------------------
function BrowserSearchPane::onDatabaseQueryResult(%this, %status, %resultStatus, %key)
{
if(%key != %this.key)
return;
// echo("RECV: " @ %status);
echo("RECV: " @ %status);
if(getField(%status,0)==0)
{
switch$(%this.state)
@ -828,6 +852,13 @@ function BrowserSearchPane::onDatabaseQueryResult(%this, %status, %resultStatus,
%this.rowNum = -1;
%this.state = "tribe";
}
case "getOnline":
error("GONLINE:" @ %status TAB %resultString);
if(getField(%status,0) == 0)
for(%str=0;%str<strLen(%resultString);%str++)
{
BrowserSearchMatchList.setRowStyle( %str, !getSubStr(%resultString,%str,1) );
}
}
}
else if (getSubStr(getField(%status,1),0,9) $= "ORA-04061")
@ -859,7 +890,10 @@ function BrowserSearchPane::onDatabaseRow(%this, %row, %isLastRow, %key)
%line = getFields(%row,1);
BrowserSearchMatchList.addRow(%this.rowNum++, %line);
if(%isLastRow)
{
%this.GetOnlineStatus();
%this.state = "done";
}
}
}
//==-- TWBTabView -----------------------------------------------------------
@ -1115,6 +1149,10 @@ function GuiMLTextCtrl::onURL(%this, %url)
PostsPopupDlg.key = LaunchGui.key++;
PostsPopupDlg.state = "adminRemovePostPlus";
databaseQuery(63, 7 TAB getFields(%url,1), PostsPopupDlg, PostsPopupDlg.key);
case "joinPublicChat":
TribePane.joinChat(getField(%url,1),0);
case "joinPrivateChat":
TribePane.joinChat(getField(%url,1),1);
//if there is an unknown URL type, treat it as a weblink..
default:
@ -1207,6 +1245,17 @@ function TribePane::onWake(%this)
tl_profile.setValue(1);
}
}
function TribePane::JoinChat(%this, %tribe, %chanType)
{
if(%chanType == 0)
%chan = "_Public";
else
%chan = "_Private";
error("CHANNEL:" @ %chan);
IRCClient::join(IRCClient::channelName(%tribe) @ %chan);
LaunchTabView.viewTab("CHAT", ChatGui, 0);
}
//-----------------------------------------------------------------------------
function TribePane::onDatabaseQueryResult(%this, %status, %resultString , %key)
{
@ -1285,19 +1334,31 @@ function TribePane::onDatabaseQueryResult(%this, %status, %resultString , %key)
case "getTribeNews":
TWBText.Clear();
%this.articleLines = 0;
TWBText.SetText("<just:left><color:ADFFFA><lmargin:10><Font:Univers Condensed:18>" @ TProfileHdr.tribeName @ " News:\n" @
"<color:82BEB9>\n");
if(getField(%resultString,0)>0)
if(GetTribeMember(TProfileHdr.tribeName))
{
%this.state = "tribeNews";
TWBText.SetText("<just:left><color:ADFFFA><lmargin:10><Font:Univers Condensed:18>" @ TProfileHdr.tribeName @ " Options:" @
"<color:82BEB9>\n\n<lmargin:20><spush><color:ADFFCC><a:forumlink" TAB TProfileHdr.tribeName @ ">Tribal Forum</a><spop>\n" @
"<spush><color:ADFFCC><a:joinPublicChat" TAB TProfileHdr.tribeName @ ">Tribal Chat: Public</a><spop>\n" @
"<spush><color:ADFFCC><a:joinPrivateChat" TAB TProfileHdr.tribeName @ ">Tribal Chat: Private</a><spop>");
}
else
{
%this.state="done";
messageBoxOK("NOTICE","No Tribe News.");
TWBText.SetText("<just:left><color:ADFFFA><lmargin:10><Font:Univers Condensed:18>" @ TProfileHdr.tribeName @ " Options:\n\n" @
"<spush><color:ADFFCC><a:joinPublicChat" TAB TProfileHdr.tribeName @ ">Enter " @ TProfileHdr.tribeName @ " Public Chat</a><spop>\n" );
}
%this.state = "done";
// if(getField(%resultString,0)>0)
// {
// %this.state = "tribeNews";
// }
// else
// {
// %this.state="done";
// messageBoxOK("NOTICE","No Tribe News.");
// }
case "getTribeInvites":
if(getField(%resultString,0) > 0)
{
@ -1925,16 +1986,21 @@ function WarriorPopupDlg::onWake( %this )
{
case 0: if(getField(GetRecord(WonGetAuthInfo(),0),0) $= TWBTabView.getTabText(TWBTabView.GetSelectedID()))
{ // visitor is owner
// WarriorPopup.add( "Clear Primary Tribe setting", 0);
WarriorPopUp.add( "Make " SPC WarriorPopup.player.name SPC "my primary tribe", 1 );
WarriorPopup.add( "Leave" SPC WarriorPopup.player.name, 2 );
WarriorPopup.add( "Go To" SPC WarriorPopup.player.name SPC "forum", 3 );
WarriorPopUp.add( strupr(WarriorPopup.Player.name), -1);
WarriorPopUp.add( "---------------------------------------------", -1);
// WarriorPopup.add( "Clear Primary Tribe setting", 0);
WarriorPopUp.add( "Make Primary Tribe", 1 );
WarriorPopup.add( "Leave Tribe", 2 );
WarriorPopup.add( "Go To Forum", 3 );
}
case 1: if(getField(GetRecord(WonGetAuthInfo(),0),0) $= TWBTabView.getTabText(TWBTabView.GetSelectedID()))
{ // visitor is owner
WarriorPopup.add( "EMail " @ getField(WarriorPopup.player.name,0), 4 );
WarriorPopup.add( "Remove" SPC getField(WarriorPopup.player.name,0) SPC " from Buddylist", 5 );
WarriorPopUp.add( strupr(getField(WarriorPopup.player.name,0)), -1);
WarriorPopUp.add( "---------------------------------------------", -1);
WarriorPopup.add( "Contact By EMail", 4 );
WarriorPopup.add( "Remove from Buddylist", 5 );
WarriorPopup.add( ".............................................", -1);
WarriorPopup.add( "Clear BuddyList", 6 );
WarriorPopup.add( "EMail BuddyList", 7 );
}
@ -2101,21 +2167,27 @@ function TribeMemberPopupDlg::onWake( %this )
break;
}
}
TribeMemberPopup.add( strUpr(TribeMemberPopup.player.name), -1);
TribeMemberPopup.add( "--------------------------------------------",-1);
switch(MemberList.CID)
{
case 0:
TribeMemberPopup.add( "Contact by EMail", 2 );
TribeMemberPopup.add( "Add To Buddylist", 4 );
TribeMemberPopup.add( "Add To Blocklist", 5 );
TribeMemberPopup.add( "Invite To Chat", 8);
if(%isMember)
{
TribeMemberPopup.add( "Kick" SPC TribeMemberPopup.player.name, 0 );
TribeMemberPopup.add( "Edit" SPC TribeMemberPopup.player.name, 1 );
TribeMemberPopup.add( "............................................", -1);
TribeMemberPopup.add( "Kick from Tribe", 0 );
TribeMemberPopup.add( "Edit Profile", 1 );
TribeMemberPopup.add( "EMail Tribe", 3 );
}
TribeMemberPopup.add( "EMail" SPC TribeMemberPopup.player.name, 2 );
TribeMemberPopup.add( "Add" SPC TribeMemberPopup.player.name SPC "To Buddylist", 4 );
TribeMemberPopup.add( "Add" SPC TribeMemberPopup.player.name SPC "To Blocklist", 5 );
case 1: TribeMemberPopup.add( "Cancel Invite To" SPC TribeMemberPopup.player.name, 6 );
TribeMemberPopup.add( "EMail Invited Player", 7 );
case 1: TribeMemberPopup.add( "Contact by EMail", 7 );
TribeMemberPopup.add( "Add To Buddylist",4);
TribeMemberPopup.add( "............................................", -1);
TribeMemberPopup.add( "Cancel Invite", 6 );
case 2: TribeMemberPopup.Add("HMMM...",8);
case 3: TribeMemberPopup.Add("HMMM...",8);
default: TribeMemberPopup.Add("HMMM...",8);
@ -2160,7 +2232,8 @@ function TribeMemberPopup::onSelect( %this, %id, %text )
"TribeMemberPopup.onSelect(12,\"call12\");","");
case 7: // 7 EMail Invited Player
LinkEMail(TribeMemberPopup.player.name);
case 8:
case 8: // 8 INVITE TO CHAT
MessageboxOK("NOTICE","This is a preview of coming functionality and is not yet available for use.");
case 9:
case 10:
case 11:

View file

@ -605,10 +605,11 @@ function StrToList(%listName, %str, %delim)
}
}
//-----------------------------------------------------------------------------
function LC_BigList::onAdd(%this)
{
LC_BigList.addStyle( 1, "Univers", 12 , "150 150 150", "200 200 200", "60 60 60" );
}
// NOTE: This control is not a ShellFancyTextList, so the addStyle method is not valid
// function LC_BigList::onAdd(%this)
// {
// LC_BigList.addStyle( 1, "Univers", 12 , "150 150 150", "200 200 200", "60 60 60" );
// }
//-----------------------------------------------------------------------------
function LC_BigList::GetOnlineStatus(%this)
{

View file

@ -1,7 +1,7 @@
//------------------------------------------
// Forums code
//------------------------------------------
$ForumCacheVersion = 8; //lucky seven...NOT!
$ForumCacheVersion = 9; //lucky seven...NOT!
$ForumCachePath = "webcache/" @ getField(wonGetAuthInfo(),3) @ "/";
$currentForumPage = 0;
$topicPageLength = 60;
@ -72,12 +72,6 @@ if(!isObject(ForumsMessageVector))
new MessageVector(ForumsMessageVector);
}
//-----------------------------------------------------------------------------
if($GuidTribes == 0)
{
%ai = wonGetAuthInfo();
$GuidTribes = getRecords(%ai,1);
}
//-----------------------------------------------------------------------------
function isModerator()
{
%result = 0;
@ -634,6 +628,11 @@ function GetTopicPosts()
function ForumsGui::onAdd( %this )
{
%this.initialized = false;
if($GuidTribes == 0)
{
%ai = wonGetAuthInfo();
$GuidTribes = getRecords(%ai,1);
}
}
//-----------------------------------------------------------------------------
function ForumsGui::onWake(%this)

View file

@ -10,9 +10,10 @@ addWebLink( "ClanBase", "www.clanbase.com" );
addWebLink( "ClanServ", "www.clanserv.com" );
addWebLink( "Dopplegangers", "www.dopplegangers.com" );
addWebLink( "Dutchbat Homeworld", "www.dutchbat-homeworld.com" );
addWebLink( "EDome", "www.edome.net" );
addWebLink( "EDome Tribes 2", "http://games.edome.net/tribes2/" );
addWebLink( "Euro Tribesplayers", "www.euro-tribesplayers.com" );
addWebLink( "eXtreme-Players", "www.eXtreme-players.de" );
addWebLink( "Game Surf", "www.gamesurf.de" );
addWebLink( "Grave Diggers Union", "www.gravediggersunion.com" );
addWebLink( "IanStorm", "www.ianstorm.com" );
addWebLink( "IMGaming", "www.imgaming.com" );

View file

@ -169,6 +169,10 @@ function NewsGui::onDatabaseRow(%this, %row,%isLastRow,%key)
}
//-----------------------------------------------------------------------------
function PostNews()
{
messageBoxYesNo("CONFIRM","Please do not submit bug reports without a tested solution, test posts or recruiting posts." NL " " NL "Continue with your submittal?","StartPostNews();");
}
function StartPostNews()
{
$NewsCategory = "";
$NewsTitle = "";

View file

@ -84,11 +84,13 @@ function ProxyEcho::onDatabaseRow(%this, %row, %isLast, %key)
function HandleDatabaseProxyResponse(%prefix, %params)
{
// error("HDPR - START:" TAB %prefix NL %params);
%id = getWord(%params, 0);
for(%qc = 0; %qc < $DBQueryCount; %qc++)
if(getWord($DBQueries[%qc], 0) == %id)
break;
if(%qc == $DBQueryCount)
{
warn("Invalid database proxy message id: " @ %id);
@ -96,6 +98,8 @@ function HandleDatabaseProxyResponse(%prefix, %params)
}
%lastPacket = getWord(%params, 1);
// error("HDPR - lastPacket" TAB %lastPacket);
%start = strpos(%params, ":") + 1;
if(!%start)
{
@ -110,17 +114,24 @@ function HandleDatabaseProxyResponse(%prefix, %params)
// concat it with any text from prior message(s) that hasn't been
// processed yet.
// error("HDPR - concat: " @ $DBQueryText[%qc] NL %newStr);
%msg = $DBQueryText[%qc] @ %newStr;
%proxyObject = getWord($DBQueries[%qc], 2);
%proxyKey = getWord($DBQueries[%qc], 3);
// error("HDPR - allrecs: " @ getWord($DBQueries[%qc],1));
if(getWord($DBQueries[%qc], 1) == 0) // we haven't receivd the first 2 recs yet
{
// error("HDPR - need first 2 recs: " @ strpos(%msg, "\\S"));
// check if we have 2 records in %msg:
%pos1 = strpos(%msg, "\\S");
// error("HDPR - POS1: " @ %pos1);
if(%pos1 != -1)
%pos2 = strpos(%msg, "\\S", %pos1 + 2);
// error("HDPR - POS2: " @ %pos2);
if(%pos1 != -1 && %pos2 != -1)
{
%resultStatus = getSubStr(%msg, 0, %pos1);
@ -131,6 +142,8 @@ function HandleDatabaseProxyResponse(%prefix, %params)
%msg = getSubStr(%msg, %pos2 + 2, 100000);
}
}
// error("HDPR - DBQ_1: " @ getWord($DBQueries[%qc], 1));
if(getWord($DBQueries[%qc], 1) == 1)
{
// start spitting out rows:
@ -144,11 +157,14 @@ function HandleDatabaseProxyResponse(%prefix, %params)
}
}
$DBQueryText[%qc] = %msg; // save off the last text...
if(%lastPacket)
{
// erase the query from the array:
// error("HDPR - ONLastPacket" TAB getWord($DBQueries[%qc], 1));
if(getWord($DBQueries[%qc], 1) == 0)
warn("Error in database query response - not enough data.");
for(%i = %qc; %i < $DBQueryCount; %i++)
{
$DBQueries[%i] = $DBQueries[%i+1];