Note: This forum is merely an archive. It is no longer possible to register or post. - StackOverflow
New Ace of Spades Forums: http://buildandshoot.com/

Boundary and spawn

Having problems creating a map? Ask around in here.

Boundary and spawn

Postby hth » Tue Mar 13, 2012 3:12 am

Was wondering how to set boundaries on a map, also wondering how to set spawn location, I'm make a small map less than 300x300
hth
Member
 
Posts: 3
Joined: Tue Mar 13, 2012 2:57 am

Re: Boundary and spawn

Postby Sandcrawler » Tue Mar 13, 2012 3:31 am

I believe Pyspades can limit boundaries (never tried it)

Boundaries:
http://code.google.com/p/pyspades/wiki/MapTxtFiles

Spawn Locations:
http://code.google.com/p/pyspades/wiki/MapScripting
Unreal Modders Haven Mapping Tutorials for Ace of Spades, as well as free map hosting.

Add your map to the downloads section on the website, and I will add it to the sandcrawler.net server.
Sandcrawler
Member
 
Posts: 21
Joined: Tue Jan 17, 2012 8:31 am

Re: Boundary and spawn

Postby BuffetOfLies » Tue Mar 13, 2012 1:44 pm

hth wrote:Was wondering how to set boundaries on a map, also wondering how to set spawn location, I'm make a small map less than 300x300


Maps are always 512X512. You could, perhaps, set a smaller map within a larger body of water and turn on water damage.
User avatar
BuffetOfLies
Moderator
 
Posts: 213
Joined: Tue Jan 17, 2012 3:40 pm

Re: Boundary and spawn

Postby hth » Tue Mar 13, 2012 8:18 pm

I'm still having difficulty understanding the spawn and intel location, can someone please help?

Thanks in advance
hth
Member
 
Posts: 3
Joined: Tue Mar 13, 2012 2:57 am

Re: Boundary and spawn

Postby BuffetOfLies » Wed Mar 14, 2012 1:30 pm

User avatar
BuffetOfLies
Moderator
 
Posts: 213
Joined: Tue Jan 17, 2012 3:40 pm

Re: Boundary and spawn

Postby hth » Wed Mar 14, 2012 6:06 pm

Thats weird, I'm not suppose to spawn in water (level 0), but the game still does it :/ the main level of my map is suppose to be level 25
hth
Member
 
Posts: 3
Joined: Tue Mar 13, 2012 2:57 am

Re: Boundary and spawn

Postby Sandcrawler » Wed Mar 14, 2012 11:26 pm

hth wrote:I'm still having difficulty understanding the spawn and intel location, can someone please help?

Thanks in advance


With the PySpades map script you would need something like this:

Code: Select all
def get_entity_location(team, entity_id):
    if entity_id == BLUE_FLAG:
        return (92, 357, 42)
    if entity_id == BLUE_BASE:
        return (93, 360, 52)
    if entity_id == GREEN_FLAG:
        return (396, 101, 42)
    if entity_id == GREEN_BASE:
        return (398, 102, 52)


This bit for example sets the location of the Blue Flag to x: 92, y: 357, z:42 (Z being the height):
if entity_id == BLUE_FLAG:
return (92, 357, 42)

The first line you set what entity/object you want to set, and the second is the location.

if you are making a smaller map, you will also need to set the player spawn location.
Unreal Modders Haven Mapping Tutorials for Ace of Spades, as well as free map hosting.

Add your map to the downloads section on the website, and I will add it to the sandcrawler.net server.
Sandcrawler
Member
 
Posts: 21
Joined: Tue Jan 17, 2012 8:31 am

Re: Boundary and spawn

Postby BuffetOfLies » Thu Mar 15, 2012 1:27 pm

hth wrote:Thats weird, I'm not suppose to spawn in water (level 0), but the game still does it :/ the main level of my map is suppose to be level 25


Not sure what your map looks like, but the game will spawn you in water if nothing of a higher elevation is available.

Something else to take note of is that the intel will spawn in the exact same place everytime, in the same order from round to round. It's location seems to be based upon something in the map itself. Kind of takes the random placement factor out of custom map games a bit but no big deal.
User avatar
BuffetOfLies
Moderator
 
Posts: 213
Joined: Tue Jan 17, 2012 3:40 pm

Re: Boundary and spawn

Postby DoomSplitter » Thu Mar 29, 2012 6:06 pm

Sorry for hijacking the thread, but I'm having issues setting up custom spawns in pyspades. Here's my code:
Code: Select all
from pyspades.constants import *
from pyspades.server import ServerConnection

def get_spawn_location(connection):       
    if connection.team is connection.protocol.blue_team:       
   x, y, z = ServerConnection.get_spawn_location(connection)       
   return ServerConnection.set_location_safe(connection, (204, 256, 50))
    if connection.team is connection.protocol.green_team:       
   x, y, z = ServerConnection.get_spawn_location(connection)       
   return ServerConnection.set_location_safe(connection, (308, 256, 50))

def get_entity_location(team, entity_id):   
    if entity_id == BLUE_BASE:             
   return (204, 240, 1)
    if entity_id == BLUE_FLAG:             
   return (204, 277, 1)
    if entity_id == GREEN_BASE:                       
   return (308, 273, 1)
    if entity_id == GREEN_FLAG:                       
   return (308, 235, 1)

The intel and bases spawn where I want them, but players don't spawn at all! The game just stays on the weapon select screen! And pyspades give me some error about "Nonetype not having position property" or something. And it's not just my script, the official example doesn't work either. So how am I supposed to fix this?
User avatar
DoomSplitter
Member
 
Posts: 316
Joined: Fri Feb 10, 2012 1:21 am

Re: Boundary and spawn

Postby BuffetOfLies » Thu Mar 29, 2012 6:53 pm

I haven't the foggiest notion. I see you posted this in the pyspades help section which is good. I'll point it out on the #pyspades channel on quakenet IRC.
User avatar
BuffetOfLies
Moderator
 
Posts: 213
Joined: Tue Jan 17, 2012 3:40 pm


Return to Mapping Help



Who is online

Users browsing this forum: No registered users and 2 guests

cron