Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Gender in Mirage - Almost solved :(


Zamin
 Share

Recommended Posts

Hello,

If your reading this, that means you opened my topic and agreed to help me. So thanks, before we even begin. :)

OK, I installed unnown's gender edits, both of them:
http://www.touchofdeathforums.com/smf/index.php/topic,31620.0.html
http://www.touchofdeathforums.com/smf/index.php/topic,31622.0.html

Those work fine, props to unnown. Now what I want to do is when I roll my mouse over an equipment, along with all the information, I want it to list which gender can equip the equipment. A picture will give a better idea:
![](http://i6.photobucket.com/albums/y220/Zamin/gender.jpg)

As you can see in the image, in the 'Requirements' category, there is aditional information. 'Gender: Male'. Basically what I want to do (also refer to pic again) is using unnown's edit, display the gender of the equipment.

So what have I done? I added the gender lable (called: descGender) in frmMirage right under Speed:
![](http://i6.photobucket.com/albums/y220/Zamin/gender2.jpg)

Also, from what I understand (and i'm normally wrong). The code must go under
```
Private Sub picInv_MouseMove
```under the line
```
desc.Caption = Trim$(Item(GetPlayerInvItemNum(MyIndex, d + 1)).desc)
```
The code that I came up with (which DOES NOT work) is:
```
'Gender
Dim gen
If Item(ItemNum).Gender = 1 Then
    gen = "Male"
ElseIf Item(ItemNum).Gender = 2 Then
    gen = "Female"
End If
descGender.Caption = gen

```
When I compile, I get an error that 'ItemNum' does not exist.

Please help me on this. I need a working script. I think I am on the right track. No?

If you read the entire post and are unable to help me, thanks for taking your time. If you are about to post, I hope your right.

-Thanks again
Link to comment
Share on other sites

Hello,

OK. 1 step closer. The cleint compiled into exe and I ran the game. When i roll the mouse over, it doesn't show me anything in the Gender bar. Not even the term 'Gender' which I made on the menu.

Perhaps I did something wrong while making the gender lable? But I think i know how to make a lable, lol. I made sure that it's called descGender so I it's not the lable. :(

-Thanks
Link to comment
Share on other sites

@[THE-KRIS:

> link=topic=50929.msg532434#msg532434 date=1251330233]
> before then if gender = 1 then stuff
>
> just before that
>
> go msgbox(item(blah).gender)
>
> tell me what it says? if you have a males then it may say 0 not 1

It highlights 'blah' and says
Variable not found.

I am sure male=1 and female=2 becuase unnown coded it like that. For sure.
Link to comment
Share on other sites

'Gender
        Dim gen As String
        Item(GetPlayerInvItemNum(MyIndex, d + 1)).Gender
        If Item(GetPlayerInvItemNum(MyIndex, d + 1)).Gender = 1 Then
            gen = "Male"
        ElseIf Item(GetPlayerInvItemNum(MyIndex, d + 1)).Gender = 2 Then
            gen = "Female"
        End If
        descGender.Caption = gen

sorry, didn't indent properly
Link to comment
Share on other sites

@[THE-KRIS:

> link=topic=50929.msg532447#msg532447 date=1251331846]
> so whered you put msgbox?

Sorry for late reply, right after```
Dim gen as string
```You told me to put this
```
Item(GetPlayerInvItemNum(MyIndex, d + 1)).Gender
```
Here:
@[THE-KRIS:

> link=topic=50929.msg532438#msg532438 date=1251330924]
> okay replace item(blah).gender with Item(GetPlayerInvItemNum(MyIndex, d + 1)).gender
> :P

EDIT: LOL, my bad. I deleted 'msgbox'
Link to comment
Share on other sites

OK, I checked, It prompts me '0'

Sry for dble post.

Note that I have two weapons, a sword and a dagger. Male can wear sword, and only female can wear dagger. It gave me '0' for both items. This means that this '0' represents the sprite (or whatever) gender, not weapon gender. Right?
Link to comment
Share on other sites

@[THE-KRIS:

> link=topic=50929.msg532455#msg532455 date=1251332884]
> so male = 0 and female = 1, just change it from  1 to 2, and 0 to 1

Ok, as mentioned above, I have two items. 1 fit for male only and 1 fit for female only.

It worked, but when I scroll my mouse, it gives me 'Male' for both. I am not good in scripting for sure, but for sure I think that this is checking the character gender, not weapon gender.
Link to comment
Share on other sites

@[SawQuart:

> Jungletoe link=topic=50929.msg532525#msg532525 date=1251347957]
> You could just make a gender skill right? Wouldnt that be much easier? You improve it by being married for certain amounts of time.

No no no, this has nothign to do with getting married xD. Not right now at least. I installed both of unnown's scripts, listed on top post. His posts allows you to have a gender system which actually works and then weapons with gender restrictions.

So now the problem is that I am trying to list what gender this equipment can wear in the Requirements Menu. You know what you scroll your mouse over an item and you get its stats. Well, I just want to add in that stat menu that which gender can equip this item.

If too confusing, I posted in main post with images and stuff.

Please help, very desperate :(
-Thanks in advance
Link to comment
Share on other sites

@Kimimaru:

> I saw that Male was equal to 1 and Female was equal to 2 on unnown's topic.

Yes, thats what i'm trying to get. But I can't find the command to call those saved values. I know they are being used in the client side in the frmItemeditor, but I dunno how to get it to Mirage and use it. If this makes any sense at all.
Link to comment
Share on other sites

hmm… did you change the 1's ans 2's to 0 and 1, like 0 = male and 1 = female, thats how sex works in eclipse, not 1 and 2 but 0 and 1.

so like

```
'Gender
Dim gen
If Item(ItemNum).Gender = 0 Then
    gen = "Male"
ElseIf Item(ItemNum).Gender = 1 Then
    gen = "Female"
End If
descGender.Caption = gen

```
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...