Seamhainn Posted January 18, 2008 Share Posted January 18, 2008 Hello! The topic says it all. Is it possible and how would the script look like? Thanks and take care Link to comment Share on other sites More sharing options...
Marius Fett Posted January 18, 2008 Share Posted January 18, 2008 void main() { object oPC = GetPCSpeaker(); object oTarget; object oSpawn; location lTarget; oTarget = GetWaypointByTag("waypoint_tag_here"); lTarget = GetLocation(oTarget); oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "creature_resref_here", lTarget); } I think that's how you do it anyway... Link to comment Share on other sites More sharing options...
Seamhainn Posted January 18, 2008 Author Share Posted January 18, 2008 void main() { object oPC = GetPCSpeaker(); object oTarget; object oSpawn; location lTarget; oTarget = GetWaypointByTag("waypoint_tag_here"); lTarget = GetLocation(oTarget); oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "creature_resref_here", lTarget); } I think that's how you do it anyway... Thanks, I'll try it out! Link to comment Share on other sites More sharing options...
stoffe Posted January 18, 2008 Share Posted January 18, 2008 I think that's how you do it anyway... Pretty much. Waypoints are normal objects and you can get an object reference for them, and from that their location, like most other world objects. (You can write the same thing with a bit less variable bloat though, even though either way should work. void main() { location lTarget = GetLocation(GetObjectByTag("waypoint_tag_here")); CreateObject(OBJECT_TYPE_CREATURE, "creature_resref_here", lTarget); } ) Link to comment Share on other sites More sharing options...
tk102 Posted January 18, 2008 Share Posted January 18, 2008 You can write the same thing with a bit less variable bloat thoughGot to go all the way. void main() { CreateObject(OBJECT_TYPE_CREATURE, "creature_resref_here", GetLocation(GetObjectByTag("waypoint_tag_here"))); } Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.