AntCore

AntCore is a custom Expression 2 extension in Suss 2 developed by and lazily named after Antagonist. It contains miscellaneous E2 functions that for some reason were never added into base E2 or even extensions. It's intended to increase both E2 capability and server performance, by adding functions that are more useful to E2 users and have less unnecessary heavy back-end physics operations. It spans across pretty much every category of E2 extensions, this can all be seen in the functions section of this page.

It's now a workshop addon: http://steamcommunity.com/sharedfiles/filedetails/?id=827052465

## Abuse prevention

Most of the functionality is limited in some way to prevent abuse and therefore removal of features. These limitations don't limit the potential of this extension, but the possibility for abuse. The most limiting factor implemented into most of the functions is self-use functions, such as E:selectWeapon(S), this means your E2 code can change your own weapon only. In addition to this all of the features with potential to be abused can be disabled individually by server managers via the console.

## Recent changes

* frameTime()
* E:isSolid()
* E:getSolid()
* pings()
* E:setClipboardText(text) (only works on owner)
* or(obj,obj), or(obj,obj,obj)
* holoVisible(indexes,players,visible), holoVisibleEnts(holos,players,visible)
* E:noCollide(R)
* spawnWireForcer(..)
* spawnEyePod(..)
* E:aimingAt()
* aimingAt(R)

## Functions

### Modified Base E2

Some functions are improved versions of E2's default functions. All recursive and iterative functions increase OPS properly. In default array.lua and table.lua one iteration is 1/3\*iterations added onto OPS, and this's uses the same formula.

### Players

Note: currently (or by default) you can only manipulate your own player.

 E:plyShadow(enable)
 E:hintPlayer(S)
 E:printPlayer(S)
 E:plyAlpha(alpha)
 E:setClipboardText(S)

### Offensive

Boom effects default whitelist:

```
"explosion","helicoptermegabomb","bloodimpact","glassimpact","striderblood","airboatgunimpact","cball_explode","manhacksparks","antliongib","stunstickimpact"

```

Turret tracers default whitelist:

```
"tracer", "ar2tracer", "helicoptertracer", "airboatgunheavytracer","lasertracer","tooltracer"

```

 boom2(pos,damage,radius)
 boomDelay()
 E:npcKill()
 E:turretShoot(directionV,damage,spread,force,count,tracer)
 turretShootLimit()
 shootBolt(pos,vel,damage)

### Weapons

Weapons functions allow players to customise their own loadout, swap their own weapons, and change their ammo amounts. Weapon and ammo types both must be whitelisted.

Default weapon whitelist:

```
"weapon_pistol","weapon_crowbar","weapon_stunstick","weapon_physcannon","weapon_shotgun","weapon_ar2","weapon_crossbow","wt_backfiregun","ragdollroper","laserpointer","remotecontroller","none","gmod_camera","weapon_fists"

```

Default ammo whitelist:

```
"pistol","357","ar2","xbowbolt","buckshot"

```

### Vehicles

Being able to control your own vehicles hugely improves the capability of E2 as it allows you to temporarily manipulate or control another player while they are in your vehicle. This system makes you more capable while not allowing abuse. This is not a new system to E2 as it already has functions such as E:printDriver() and E:killPod() which would be greatly abuse-able if allowed to be used on any player.

 E:setInflictor(newinflictor)
 E:podThirdPerson(enabled)
 E:podThirdPersonDist(distance)
 E:podSwapDriver(pod2)
 E:ejectPod(position)

### Physics

This category offers a lot of physics based functionality to E2. Many of these functions drastically improve server performance over existing E2 alternatives. Such as E:setVelocity/E:setAngVel compared to E:applyForce/E:applyAngForce.

### Wire spawns

\* Most of this already exists in wire spawn core but it's improved here.

 spawnEgpHud(pos,ang)
 spawnEgpEmitter(pos,ang)
 spawnWireUser(model,range,pos,ang)
 spawnExpression2(model,pos,ang)
 spawnTextEntry(model,pos,ang,freeze,disableuse)
 spawnTextScreen(model,pos,ang,freeze)
 spawnButton(model,pos,ang,freeze),
spawnButton(model,pos,ang,freeze,on,off)
 spawnWireForcer(model,pos,ang,frozen)
spawnWireForcer(model,pos,ang,frozen,range,beam,reaction)
 spawnEyePod(pos,ang,frozen)
spawnEyePod(pos,ang,frozen,defaultzero,cumulative,min,max)