| | #1 (permalink) | ||||||||||||
| FORERO UASU Ingreso: mayo-2008 Edad: 15
Mensajes: 98
Poder: 45 ![]() ![]() ![]() | Bueno este sistema es algo que no esta en Fenix AO, y creo que todabia no esta, me acuerdo que en la Beta con mis amigos usabamos el comando /DESC como casamiento todo el mundo lo usaban jaja taba re de moda xD. Por eso decidi adaptar un codigo de casamiento de 0.11.5. Este sistema carga a traves del Charfile es por ello que necesitamos el sistema hecho por Matute, extraido por Agus Rlz. El codigo lo pueden encontrar por Google El comando es muy sencillo y lo modifke un poco. Para casarse se necesitan 2 torneos ganados al igual que tu pareja, al poner /CASAR si no tienes los torneos te va a decir que no tienes suficientes torneos para realizar esta operacion, lo mismo con tu pareja, es por ello que los dos necesitan 2 torneos ganados, tambien puse el comando /DIVORCIO para divorciarse, esa operacion no tiene ningun requisito, este comando carga de los charfiles Bueno Comenzemos SERVIDOR Buscamos: Código: Case "#/" Código: Case "#_" If UserList(UserIndex).flags.TargetUser > 0 Then Dim tempIndex As Integer tempIndex = UserList(UserIndex).flags.TargetUser If UserList(UserIndex).flags.Muerto = 1 Then Exit Sub If UserList(tempIndex).flags.Muerto = 1 Then Call SendData(ToIndex, UserIndex, 0, "|| !!No podes casarte con un muerto!!" & FONTTYPE_INFO) Exit Sub End If If tempIndex = UserIndex Then Call SendData(ToIndex, UserIndex, 0, "||No puedes casarte con vos mismo..." & FONTTYPE_INFO) Exit Sub End If If UserList(UserIndex).Faccion.Torneos < 2 Then Call SendData(ToIndex, UserIndex, 0, "||Necesitas tener dos torneos ganados para casarte!." & FONTTYPE_INFO) Exit Sub End If If UserList(UserIndex).Genero = UserList(tempIndex).Genero Then Call SendData(ToIndex, UserIndex, 0, "||Debes casarte con alguien del sexo opuesto." & FONTTYPE_INFO) Exit Sub End If If UserList(tempIndex).Faccion.Torneos < 2 Then Call SendData(ToIndex, UserIndex, 0, "||Tu pretendiente debe superar al menos dos torneos para casarse contigo." & FONTTYPE_INFO) Exit Sub End If If Distancia(UserList(tempIndex).POS, UserList(UserIndex).POS) > 3 Then Call SendData(ToIndex, UserIndex, 0, "||Tenes que estar junto a la persona con la cual queres casarte." & FONTTYPE_INFO) Exit Sub End If If UserList(UserIndex).flags.Casado <> "" Then Call SendData(ToIndex, UserIndex, 0, "||Ya tienes una pareja." & FONTTYPE_INFO) Exit Sub End If If UserList(tempIndex).flags.Casado <> "" Then Call SendData(ToIndex, UserIndex, 0, "||El usuario ya tiene una pareja." & FONTTYPE_INFO) Exit Sub End If UserList(UserIndex).flags.Casandose = tempIndex If UserList(tempIndex).flags.Casandose <> UserIndex And UserList(tempIndex).flags.Casandose <> 0 Then Call SendData(Sentarget.ToIndex, UserIndex, 0, "||El usuario esta casandose con otra persona." & FONTTYPE_INFO) Exit Sub End If If UserList(tempIndex).flags.Casandose = UserIndex Then UserList(tempIndex).flags.Casado = UserList(UserIndex).Name UserList(UserIndex).flags.Casado = UserList(tempIndex).Name UserList(UserIndex).flags.Casandose = 0 UserList(tempIndex).flags.Casandose = 0 Call SendData(ToIndex, UserIndex, 0, "||Te has casado con " & UserList(tempIndex).Name & "!!" & FONNTYPE_CASADO) Call SendData(ToIndex, tempIndex, 0, "||Te has casado con " & UserList(UserIndex).Name & "!!" & FONTTYPE_CASADO) Else SendData Sendatrget.ToIndex, tempIndex, 0, "||" & UserList(UserIndex).Name & " este ofreciendote matrimonio, escribe /CASAR luego de cliquear sobre el para aceptar su propuesta." & FONTTYPE_INFO Exit Sub End If Exit Sub End If Buscamos: Código: Case "#S" Código: Case "#=" Dim nombredivor2 As String If UserList(UserIndex).flags.Casado = "" Then Call SendData(ToIndex, UserIndex, 0, "||??No estas casado.!!." & FONTTYPE_INFO) Exit Sub End If nombredivor2 = UserList(UserIndex).flags.Casado If NameIndex(UserList(UserIndex).flags.Casado) < 1 Then WriteVar App.Path & "Charfile" & UserList(UserIndex).flags.Casado & ".chr", "FLAGS", "Casado", "0" UserList(UserIndex).flags.Casado = "" Else UserList(NameIndex(UserList(UserIndex).flags.Casado)).flags.Casado = "" UserList(UserIndex).flags.Casado = "" Exit Sub End If Call SendData(ToAll, 0, 0, "TW" & 27) Call SendData(ToAll, 0, 0, "||" & UserList(UserIndex).Name & " y " & nombredivor2 & " se divorciaron!!!" & "fonttype_guild") Debug.Print "Buen divorcio" Exit Sub Código: flags.Envenenado = RS!Envenenado . Código: flags.Casado = RS!Casado Código: Call WriteVar(UserFile, "FLAGS", "Muerto", val(UserList(UserIndex).flags.Muerto)) Código: Call WriteVar(UserFile, "FLAGS", "CASADO", val(UserList(UserIndex).flags.Casado)) Código: Public Const FONTTYPE_TALK = "~255~255~255~0~0" Código: Public Const FONNTYPE_CASADO = "~255~150~50~1~0" Código: Type UserFlags Código: Casado As String Casandose As Integer UserList(UserIndex).flags.Envenenado = 0 Abajo agregamos: Código: UserList(UserIndex).flags.Casado = 0 Código: UserList(UserIndex).flags.Escondido = 0 Código: UserList(UserIndex).flags.Casado = 0 UserList(UserIndex).flags.Casado = "" UserList(UserIndex).flags.Casandose = 0 Cita:
Remplazen esto: Código: If UserList(UserIndex).Faccion.Torneos < 2 Then Call SendData(ToIndex, UserIndex, 0, "||Necesitas tener dos torneos ganados para casarte!." & FONTTYPE_INFO) Exit Sub End If Código: If UserList(UserIndex).Faccion.ELV< 20 Then Call SendData(ToIndex, UserIndex, 0, "||Necesitas ser superior a nivel 20para casarte!." & FONTTYPE_INFO) Exit Sub End If Código: If UserList(tempIndex).Faccion.Torneos < 2 Then Call SendData(ToIndex, UserIndex, 0, "||Tu pretendiente debe superar al menos dos torneos para casarse contigo." & FONTTYPE_INFO) Exit Sub End If Código: If UserList(tempIndex).Faccion.ELV < 20 Then Call SendData(ToIndex, UserIndex, 0, "||Tu pretendiente debe superar al menos el nivel 20 para casarse contigo." & FONTTYPE_INFO) Exit Sub End If Buscamos: Código: Case "/INFORMACION ReplaceData = "#Z" Código: Case "/CASAR" ReplaceData = "#_" Case "/DIVORCIO" ReplaceData = "#="
__________________ Última edición por [KenJiN]; 08-nov-2008 a las 17:24. | ||||||||||||
| | |
| Sponsored Links |
![]() |
| Marcadores |
| Herramientas | |
| Desplegado | |
|
|
Te recomendamos visitar estos sitios
|