ID:262631
 
Code:
mob/proc
Guild()
if (src.Level >= 75)
new/mob/ll/verb/Guild_Create
new/mob/ll/verb/Quit_Guild
new/mob/ll/verb/Guild_Who
alert("You have now unlocked The Guild Verbs")


Problem description:its not giveing me my verbs idk why

You can't just create verbs like that. Verbs don't work like that. You need to add the verb path types to your verbs list.

In another note, you had hidden usr abuse. The first argument for alert() defaults to usr.

mob/proc/Guild()
if(src.Level >= 75)
// add the path type to the verbs list
src.verbs += /mob/ll/verb/Guild_Create
src.verbs += /mob/ll/verb/Quit_Guild
src.verbs += /mob/ll/verb/Guild_Who
alert(src, "You have now unlocked The Guild Verbs")


~~> Dragon Lord
In response to Unknown Person
mob/proc/LevelUp()
if (ExpNeeded <= 0)
Level ++
Ranking(src)
ExpNeeded = 50 * Level
src << "<font color = green>Level Up! Current Level: [Level]"
switch (Race)
if ("Human")
MaxHp += 10
MaxMana += 3
MaxEnergy += 3
Strength += 3
Vitality += 3
Knowledge += 3
Wisdom += 3
Agility += 3
Luck += 3
statpoints = rand(1,11)

mob/proc/Guild()
if(src.Level >= 75)
src.verbs += /mob/ll/verb/Guild_Create
src.verbs += /mob/ll/verb/Quit_Guild
src.verbs += /mob/ll/verb/Guild_Who
alert(src, "You have now unlocked The Guild Verbs")

its still not adding them for some reason
mob/ll/verb/Guild_Create()//create a verb for people to create there own guild
set category = "Guild"
var/savefile/F = new("Guilds.sav")
global.guilds = F["Guilds.sav"]
var/guildname = input("What do you want your guilds name to be?")as text//ask for the guilds name
src.guild = "[guildname]"//set there guild to the guild they just made
src.guildowner = 1//make it so there the owner of there gulid
src << "You have created [src.guild]"//tell them that they have joined
src.GiveOwner()
guilds += list("[guildname]")//add the guild to the list of all guilds currently created.

mob/ll/verb/Quit_Guild()//create a verb where they can quit
set category = "Guild"
if(src.guild == "None")
src << "You are not in a guild"
return()
else//if they are in a guild
if(src.guildowner == 1)//if they are the owner of the guild
src << "Please give up ownership before quiting."//make it so they have to give soemone else owner first
return()
else
src.guild = "None"//Not in a guild anymore
return()

mob/ll/verb/Guild_Who()//create a verb that lists who are in your guild
set category = "Guild"
for(var/mob/M in world)//all the mobs
if(M.guild == src.guild)//if M is in your guild
if(M.guild == "None")//if there not in a guild, and your not
return()//send em back
else//otherwise
src << "The Following are in your guild:"//give em a little message, then
src << "[M]"//tell them
In response to National Guardsmen
How are you calling the Guild() proc? Show me the snippet where the Guild() proc is called.

~~> Dragon Lord
In response to Unknown Person
mob/proc/LevelUp()
if (ExpNeeded <= 0)
Level ++
Ranking(src)
ExpNeeded = 50 * Level
src << "<font color = green>Level Up! Current Level: [Level]"
switch (Race)
if ("Human")
MaxHp += 10
MaxMana += 3
MaxEnergy += 3
Strength += 3
Vitality += 3
Knowledge += 3
Wisdom += 3
Agility += 3
Luck += 3
statpoints = rand(1,11)
Guild()
if ("Elf")
MaxHp += 8
MaxMana += 4
MaxEnergy += 4
Strength += 3
Vitality += 2
Knowledge += 3
Wisdom += 3
Agility += 4
Luck += 4
statpoints = rand(1,11)
Guild()
if ("Drow Elf")
MaxHp += 9
MaxMana += 5
MaxEnergy += 5
Strength += 4
Vitality += 3
Knowledge += 4
Wisdom += 4
Agility += 5
Luck += 5
statpoints = rand(1,11)
Guild()
if ("WereWolf")
MaxHp += 9
MaxMana += 5
MaxEnergy += 5
Strength += 4
Vitality += 3
Knowledge += 4
Wisdom += 4
Agility += 5
Luck += 5
statpoints = rand(1,11)
Guild()
if ("Demon")
MaxHp += 9
MaxMana += 5
MaxEnergy += 5
Strength += 4
Vitality += 3
Knowledge += 4
Wisdom += 4
Agility += 5
Luck += 5
statpoints = rand(1,11)
Guild()
if ("Demonic Half Breed")
MaxHp += 9
MaxMana += 5
MaxEnergy += 5
Strength += 4
Vitality += 3
Knowledge += 4
Wisdom += 4
Agility += 5
Luck += 5
statpoints = rand(1,11)
Guild()
if ("Vampire")
MaxHp += 9
MaxMana += 5
MaxEnergy += 5
Strength += 4
Vitality += 3
Knowledge += 4
Wisdom += 4
Agility += 5
Luck += 5
statpoints = rand(1,11)
Guild()

theres were im calling it im callingit in lvl up
In response to National Guardsmen
Well, are you level 75 or above?
It would be good to delete all those instances of "Guild()" and make one instance aligned with the if() statements.
Also, if you're adding multiple verbs out of a same type path, use
src.verbs+=typesof(/mob/ll/verb)
In response to National Guardsmen
mob/proc/LevelUp()
if (src.ExpNeeded <= 0)
src.Level ++
Ranking(src)
src.ExpNeeded = 50 * src.Level
src << "<font color = green>Level Up! Current Level: [Level]"
switch (src.Race)
if ("Human")
src.MaxHp += 10
src.MaxMana += 3
src.MaxEnergy += 3
src.Strength += 3
src.Vitality += 3
src.Knowledge += 3
src.Wisdom += 3
src.Agility += 3
src.Luck += 3
src.statpoints += rand(1,11)
if ("Elf")
src.MaxHp += 8
src.MaxMana += 4
src.MaxEnergy += 4
src.Strength += 3
src.Vitality += 2
src.Knowledge += 3
src.Wisdom += 3
src.Agility += 4
src.Luck += 4
src.statpoints += rand(1,11)
if ("Drow Elf")
src.MaxHp += 9
src.MaxMana += 5
src.MaxEnergy += 5
src.Strength += 4
src.Vitality += 3
src.Knowledge += 4
src.Wisdom += 4
src.Agility += 5
src.Luck += 5
src.statpoints = rand(1,11)
if ("WereWolf")
src.MaxHp += 9
src.MaxMana += 5
src.MaxEnergy += 5
src.Strength += 4
src.Vitality += 3
src.Knowledge += 4
src.Wisdom += 4
src.Agility += 5
src.Luck += 5
src.statpoints += rand(1,11)
if ("Demon")
src.MaxHp += 9
src.MaxMana += 5
src.MaxEnergy += 5
src.Strength += 4
src.Vitality += 3
src.Knowledge += 4
src.Wisdom += 4
src.Agility += 5
src.Luck += 5
src.statpoints += rand(1,11)
if ("Demonic Half Breed")
src.MaxHp += 9
src.MaxMana += 5
src.MaxEnergy += 5
src.Strength += 4
src.Vitality += 3
src.Knowledge += 4
src.Wisdom += 4
src.Agility += 5
src.Luck += 5
src.statpoints += rand(1,11)
if ("Vampire")
src.MaxHp += 9
src.MaxMana += 5
src.MaxEnergy += 5
src.Strength += 4
src.Vitality += 3
src.Knowledge += 4
src.Wisdom += 4
src.Agility += 5
src.Luck += 5
src.statpoints += rand(1,11)
Guild(src)


I want this known, that all of these different switch statements and excess BS isn't needed. Why can't you just set a var at creation time that determines this? Not to mention this looks very sloppy.