mirror of
https://github.com/ProjectSWGCore/NGECore2.git
synced 2026-09-11 21:45:43 -04:00
Added MissionObject Baselines, Waypoints can be added via Planetary Map now
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
import sys
|
||||
|
||||
def setup():
|
||||
return
|
||||
|
||||
def run(core, actor, target, commandString):
|
||||
|
||||
commandArgs = commandString.split("(^-,=+_)color_13548(,+-=_^)=1")
|
||||
|
||||
newString = commandArgs[1]
|
||||
print (newString)
|
||||
cmdService = core.commandService
|
||||
cmdService.callCommand(actor, 'waypoint', None, newString) # No need to re-create a script
|
||||
return
|
||||
@@ -67,6 +67,24 @@ def run(core, actor, target, commandString):
|
||||
actorPlayer.waypointAdd(waypoint)
|
||||
actor.sendSystemMessage('A waypoint has been created in your datapad at your location.', 0)
|
||||
return
|
||||
|
||||
#/wp planet x z y name
|
||||
elif len(commandArgs) >= 3 and isFloat(commandArgs[2]) and isFloat(commandArgs[3]) and isFloat(commandArgs[4]):
|
||||
waypoint = core.objectService.createObject('object/waypoint/shared_waypoint.iff', core.terrainService.getPlanetByName(commandArgs[1]), float(commandArgs[2]), float(commandArgs[4]), float(commandArgs[3]))
|
||||
waypoint.setActive(True)
|
||||
waypoint.setColor(WaypointObject.BLUE)
|
||||
name = commandString.split(" ", 5)
|
||||
print (name)
|
||||
if name == "":
|
||||
name = "Waypoint"
|
||||
|
||||
waypoint.setName(name[5])
|
||||
waypoint.setPlanetCRC(crc.StringtoCRC(actor.getPlanet().getName()))
|
||||
actorPlayer.getWaypoints().add(waypoint)
|
||||
actorPlayer.waypointAdd(waypoint)
|
||||
actor.sendSystemMessage('A waypoint has been created in your datapad at your location.', 0)
|
||||
return
|
||||
|
||||
#/wp NAME
|
||||
else:
|
||||
waypoint = core.objectService.createObject('object/waypoint/shared_waypoint.iff', actor.getPlanet(), actor.getWorldPosition().x, actor.getWorldPosition().z, actor.getWorldPosition().y)
|
||||
|
||||
Reference in New Issue
Block a user