if(characters.len>1)
alert("You already have a character, please delete your current account and try again","ERROR!")
login.dm:148:error:characters.len:undefined var
whats wrong?
ID:268236
May 4 2004, 12:57 pm
|
|
if(characters.len>1) login.dm:148:error:characters.len:undefined var whats wrong? |
In response to Jon88
|
|
Im just trying to make a proc when they create a character if they already have one they cant create another one and i was told to use characters.len
|
In response to Vash_616
|
|
Vash_616 wrote:
Im just trying to make a proc when they create a character if they already have one they cant create another one and i was told to use characters.len If you showd the code it would help. |
In response to Vash_616
|
|
I think what 'XzDog' and 'Jon' meant was 'show where you define your characters variable', and the code around that.
[edit] Sorry for not being specific enough, but i was talking about the people who were trying to help him [/edit] |
In response to Lazyboy
|
|
He obviously didn't. He simply heard somoene say to use "characters.len", and assumed that plugging that into his code would work.
|
In response to Garthor
|
|
mob/creating_character There any help would be very greatful as i can not go on until this is fixed. |
In response to Vash_616
|
|
Vash_616 wrote:
mob/creating_character I'm just going to assume that you meant to indent that under mob/creating_character/New(), since you can't call a proc like that. |
In response to Goku72
|
|
Yes i know but that doesnt help me with my current problem.
|
In response to Vash_616
|
|
var/list/characters = client.base_CharacterNames() Your problem would have to be in base_CharacterNames(). Whatever it's returning isn't a list. Did you copy and paste part of the base_CharacterNames() proc from the library and somehow mangle or alter it? |
In response to Hedgemistress
|
|
No its a downloaded library but i didnt edit or mangle it
|
try
if (length(characters) > 1) |
In response to RVegeta
|
|
RVegeta wrote:
try > if (length(characters) > 1) Don't put usr in a proc. |
In response to Vash_616
|
|
Nope that didnt work either Rvegeta.
|
In response to Vash_616
|
|
Vash_616 wrote:
Nope that didnt work either Rvegeta. If you're not going to view posts in threaded mode, be absolutely sure you're replying to the right post. In this case you didn't. Lummox JR |
In response to Lummox JR
|
|
2 Days Bump.
|
You need to define the characters var as a list.
You probably have:
|
In response to Foomer
|
|
Foomer wrote:
You need to define the characters var as a list.
|
In response to Vash_616
|
|
Everytime i post a problem, no seems to help find a solution =/
|
characters does not have a len variable. A bit more code, like where you define characters, would be helpful.