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

jsorr2

Members
  • Posts

    31
  • Joined

  • Last visited

    Never

Posts posted by jsorr2

  1. Trying to call Monster's name from file. Come's up with a blank. What am I doing wrong?

    ```

    Sub SaveMonsters()

    Dim i As Long

    For i = 1 To MAX_MONSTERS

    Call SaveMonster(i)

    Next

    End Sub

    Sub SaveMonster(ByVal MonstersNum As Long)

    Dim filename As String

    Dim F As Long

    filename = App.path & "\data\Monsters\Monsters" & MonstersNum & ".dat"

    F = FreeFile

    Open filename For Binary As #F

    Put #F, , Monsters(MonstersNum)

    Close #F

    End Sub

    Sub LoadMonsters()

    Dim filename As String

    Dim i As Long

    Dim F As Long

    Call CheckMonsters

    For i = 1 To MAX_MONSTERS

    filename = App.path & "\data\BaseMonster" & ".txt"

    F = FreeFile

    Open filename For Binary As #F

    Get #F, , Monsters(i)

    Close #F

    Next

    End Sub

    Sub CheckMonsters()

    Dim i As Long

    For i = 1 To MAX_MONSTERS

    If Not FileExist("\Data\Monsters\Monsters" & i & ".dat") Then

    Call SaveMonsters(i)

    End If

    Next

    End Sub

    Sub ClearMonster(ByVal index As Long)

    Call ZeroMemory(ByVal VarPtr(Monsters(index)), LenB(Monsters(index)))

    Monsters(index).MonstersName = vbNullString

    End Sub

    Sub ClearMonsters()

    Dim i As Long

    For i = 1 To MAX_MONSTERS

    Call ClearMonster(i)

    Next

    End Sub

    ```
    ```

    Public Function GetFileName(ID As Long) As String

    GetFileName = App.path & "\data\Monsters\Monsters" & ID & ".dat"

    End Function

    Public Function GetMonstersName(ID As Long) As String

    Dim filename As String

    If ID > 0 And ID <= 50 Then

    filename = GetFileName(ID)

    GetMonstersName = GetVar(filename, CStr(ID), "Name")

    Else

    GetMonstersName = OutBounds

    End If

    End Function

    ```
  2. I'm curious, if I had this writting in the ini file:

    [1]

    Stats: 6,7,8,9,10

    And I wanted to call them individually into the server,

    strength = 1st value,

    Endurance = 2nd value

    Intelligence = 3rd value

    etc..

    How could I grab the individual values?

    ```

    Class(i).stat(Stats.Strength) = Val(GetVar(filename, "" & i, "Stats", ????))

    Class(i).stat(Stats.Endurance) = Val(GetVar(filename, "" & i, "stats" ?????))

    ```

    thanks ![:D](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/biggrin.png)
  3. If I had a database in Microsoft access, which pre-defined the party monsters characteristics (str/int/dex), where could I initialize the ADO code to access it server side so that when the player logs in, the player loads it's party, from when they last logged off.

    example:

    Player finds goblin lvl 2 (which in the database is object [1]), asks it to join the party. Goblin has 2 str, which is different from a 3str goblin. They log out and then when they log in, the Goblin with 2str is still in their party.

    Would this fall under sub PlayerJoin or some sort of sub Party_(insert words here)?
  4. How about this:

    ```

    Case Evt_OpenShop

    Call SendOpenShop(index, .Data(1))

    TempPlayer(index).InShop = .Data(1)

    GoTo EventQuit

    ```

    or this:

    ```

    Sub SendOpenShop(ByVal index As Long, ByVal shopNum As Long)

    Dim Buffer As clsBuffer

    Set Buffer = New clsBuffer

    Buffer.WriteLong SOpenShop

    Buffer.WriteLong shopNum

    SendDataTo index, Buffer.ToArray()

    Set Buffer = Nothing

    End Sub

    ```

    also, I must be tripping, because I thought the comment in the code i posted earlier would mean that was it. I mean,

    ' Check for a shop, and if so open it

    the open it part, couldn't that be edited?
  5. Alright, where could I add a randomiser in this code then? ![:D](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/biggrin.png)

    ```

    ' Check for a shop, and if so open it

    If .Type = TILE_TYPE_SHOP Then

    x = .Data1

    If x > 0 Then ' shop exists?

    If Len(Trim$(Shop(x).Name)) > 0 Then ' name exists?

    SendOpenShop index, x

    TempPlayer(index).InShop = x ' stops movement and the like

    End If

    End If

    End If

    ```
  6. I'm trying to randomise the event 'drawShop' so that it's about a 25% chance to activate it _on touch_. (For Eclipse Advance v3.0)

    What part of this code would I modify to change it from 'always open gui' to '25% chance to open gui_shop'?

    ```

    Public Sub DrawShop()

    Dim I As Long, X As Long, Y As Long, itemNum As Long, ItemPic As Long, Left As Long, Top As Long, Amount As Long, colour As Long

    Dim Width As Long, Height As Long

    ' render the window

    Width = GUIWindow(GUI_SHOP).Width

    Height = GUIWindow(GUI_SHOP).Height

    'EngineRenderRectangle Tex_GUI(23), GUIWindow(GUI_SHOP).x, GUIWindow(GUI_SHOP).y, 0, 0, width, height, width, height, width, height

    RenderTexture Tex_GUI(20), GUIWindow(GUI_SHOP).X, GUIWindow(GUI_SHOP).Y, 0, 0, Width, Height, Width, Height

    ' render the shop items

    For I = 1 To MAX_TRADES

    itemNum = Shop(InShop).TradeItem(I).Item

    If itemNum > 0 And itemNum <= MAX_ITEMS Then

    ItemPic = Item(itemNum).Pic

    If ItemPic > 0 And ItemPic <= numitems Then

    Top = GUIWindow(GUI_SHOP).Y + ShopTop + ((ShopOffsetY + 32) * ((I - 1) \ ShopColumns))

    Left = GUIWindow(GUI_SHOP).X + ShopLeft + ((ShopOffsetX + 32) * (((I - 1) Mod ShopColumns)))

    'EngineRenderRectangle Tex_Item(itempic), left, top, 0, 0, 32, 32, 32, 32, 32, 32

    RenderTexture Tex_Item(ItemPic), Left, Top, 0, 0, 32, 32, 32, 32

    ' If item is a stack - draw the amount you have

    If Shop(InShop).TradeItem(I).ItemValue > 1 Then

    Y = GUIWindow(GUI_SHOP).Y + Top + 22

    X = GUIWindow(GUI_SHOP).X + Left - 4

    Amount = CStr(Shop(InShop).TradeItem(I).ItemValue)

    ' Draw currency but with k, m, b etc. using a convertion function

    If CLng(Amount) < 1000000 Then

    colour = White

    ElseIf CLng(Amount) > 1000000 And CLng(Amount) < 10000000 Then

    colour = Yellow

    ElseIf CLng(Amount) > 10000000 Then

    colour = BrightGreen

    End If

    RenderText Font_Default, ConvertCurrency(Amount), X, Y, colour

    End If

    End If

    End If

    Next

    ' draw buttons

    For I = 23 To 23

    ' set co-ordinate

    X = GUIWindow(GUI_SHOP).X + Buttons(I).X

    Y = GUIWindow(GUI_SHOP).Y + Buttons(I).Y

    Width = Buttons(I).Width

    Height = Buttons(I).Height

    ' check for state

    If Buttons(I).state = 2 Then

    ' we're clicked boyo

    'EngineRenderRectangle Tex_Buttons_c(Buttons(i).PicNum), x, y, 0, 0, width, height, width, height, width, height

    RenderTexture Tex_Buttons_c(Buttons(I).PicNum), X, Y, 0, 0, Width, Height, Width, Height

    ElseIf (GlobalX >= X And GlobalX <= X + Buttons(I).Width) And (GlobalY >= Y And GlobalY <= Y + Buttons(I).Height) Then

    ' we're hoverin'

    'EngineRenderRectangle Tex_Buttons_h(Buttons(i).PicNum), x, y, 0, 0, width, height, width, height, width, height

    RenderTexture Tex_Buttons_h(Buttons(I).PicNum), X, Y, 0, 0, Width, Height, Width, Height

    ' play sound if needed

    If Not lastButtonSound = I Then

    PlaySound Sound_ButtonHover, -1, -1

    lastButtonSound = I

    End If

    Else

    ' we're normal

    'EngineRenderRectangle Tex_Buttons(Buttons(i).PicNum), x, y, 0, 0, width, height, width, height, width, height

    RenderTexture Tex_Buttons(Buttons(I).PicNum), X, Y, 0, 0, Width, Height, Width, Height

    ' reset sound if needed

    If lastButtonSound = I Then lastButtonSound = 0

    End If

    Next

    ' draw item descriptions

    DrawShopItemDesc

    End Sub

    ```

    cheers ![;)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/wink.png)
  7. You'd think that the amount of people who ask help for pokemon mmo's, you'd all be highly skilled in the arts of coding one, so much so that it would be included in your resume.

    I have a big list of things (12+) that I need added to my Eclipse Advance engine, which I will spoiler at the end of the post. If anyone can accomplish any number in the spoiler, pm me or reply here and we can settle a price.

    here are some maps of work that we've done:

    pic 1

    >! ![](http://i48.tinypic.com/208w87t.png)

    pic 2

    >! ![](http://i49.tinypic.com/2n85wki.png)

    pic 3

    >! ![](http://i49.tinypic.com/idx99y.png)

    Let me just make a side note here, if the only thing making you **not** help is Eclipse advance, we **can** convert to origins, if you are willing to help.

    >! **These all can be explained in depth more, they are just simple broad terms so you can have a basic understanding of what it is.**
    >! 1\. battle start coding for a select amount of tiles (such as grass, cave floors), which intiaites battle interface.
    >! 2\. buttons on side of screen that do (will provide screenshots of what every window looks like):
    >! party: current party members (max 6). If party pokemon clicked, 4 options: move up, move down, information, cancel. top party member cant move up, bottom party member cant move down. If stats is clicked, open new window in middle of screen showing: picture of pokemon, ID number, trainer number, type of pokemon, nature, lvl, gender, name/nickname, no it is in pokedex.
    >! bag: shows how much money - 4 mini slots in bag for : items, pokeballs, key items, hm/tm
    >! friends list: 2 mini areas for friends and ignored
    >! personal stats: open new little box in middle of game that states Id no, name, pvp (win number and lose number), pokedex (seen number, caught number), money number, total time played, pvp rank.
    >! pokedex: open new box in middle of game, with options to scroll through 493 profiles of pokemon. It will include height, colour, weight, number pokemon they are, a scroll bar, sort (no., name, type), mini picture of pokemon selected, short description of pokemon, total amount seen / 493, total amount caught /493.
    >! settings: sound, CPU usage (high, med, low), change password (new box asking for current password, new password, retyped password), logout, accept, cancel.
    >! 3\. battle screen to have 4 buttons:
    >! fight: opens up menu where 4 moves can be selected depending on pokemon
    >! run: chance to end battle depending on pokemon level compared to opponents
    >! bag: open gui bag options as stated above.
    >! pokemon: open box in middle of window and show current party members (max 6). If clicked, ask: swap pokemon (which will change current party member to selected member), information (new box in window showing, cancel.
    >! 4.
    >! Battle screen to have 2 bars, 1 for your pokemon, 1 for opponents:
    >! hp bar: hit points left of your pokemon, and same for opponent, hp bar to alos have number underneath indicating out of what is left.
    >! Level: level of your pokemon and level of theirs.
    >! pokeball: pokeball on their bar indicating if caught or not.
    >! gender: gender of yours and their pokemon.
    >! 5.
    >! Wild pokemon battles:
    >! wait for player to select move and then calculate whether player's pokemon or wild pokemon has higher speed stat. Higher speed goes first. Get wild pokemon to pick a random move out of its select (max 4 moves). Make pokemon be able to be caught by player, if player has a type of pokeball (6 types). Make pokemon go into party, if caught, and if space. If no space, pokemon PC, which can be accessed in pokecenter. Make pokemon easier to catch if lower hp and if status effect on it.
    >! 6.
    >! moves:
    >! there are a huge list of moves, each with their own "number of uses", "power" and "type".
    >! Make some move types 2x stronger on the weak type of pokemon. and 2x weaker on the resistant type of pokemon. These have to be calculated while in either a wild or trainer battle. everytime a moved is used, let the "number of uses" go down by 1 from maximum, and remember lost number until pokemon is -refreshed- at a pokecenter.
    >! 7.
    >! Pokemon center:
    >! Allow pokemon to be refreshed back to full hp, full move uses, remove ailgments, revive from death, if talk to an npc inside.
    >! If accessing computer, open new window and show pokemon that have been stored inside, the "box" number (maximum 16), and ability to scroll through boxes. when pokemon is clicked in box: withdraw, info, cancel. When party pokemon is clicked while box is open: deposit, info, cancel. When box is closed, shuffle all pokemon to left, so there are no spaces left.
    >! 8.
    >! npc battle:
    >! 4 buttons:
    >! move, bag, run, pokemon
    >! most of stuff same from wild pokemon battle, except the pokeball icon to show if caught of not is not there, and the npc's pokemon will pick a move dependant on whether it is super effective, or "normal" effective against the players pokemon. (e.g., water type move against players fire type pokemon)
    >! Can't use run in npc battles, cant catch NPC's pokemon, if switching pokemon, counts as your turn and opponent gets an attack, however switch will always go first, unless a specific move is used (pursuit) in which case its power is doubled.
    >! 9.
    >! Ailgments:
    >! burn: pokemon is hurt 1/16th its hp every turn. its physical attacked is reduced by half.
    >! poison: pokemon is hurt 1/16th hp every turn.
    >! deadly poison: pokemon is hurt 1/16th hp, compounding (1/16th, next turn 2/16th, next turn 4/16th, etc.)
    >! paralyzed: pokemon has chance to not be able to attack. pokemons speed is reduced by half.
    >! While out of battle if pokemon is poisoned or deadly poisoned, take away 1/50th hp every step taken.
    >! 10.
    >! Pokemon:
    >! pokemon will each have individual stats
    >! pokemon will each have a hidden value to alter their stats (0-31)
    >! each pokemon can gain an additional stat called evs. 4 evs in a stat = 1 stat point added (maximum 510 evs)
    >! there are 6 stats:
    >! hp: health
    >! p. att: physical attack
    >! sp. attack: special attack
    >! def: defence (against physical attacks)
    >! sp. def: special defense (against special attacks)
    >! spe: speed
    >! I can provide calculators for the damage.
    >! Each wild pokemon will give an ev to the pokemon who killed it.
    >! each wild pokemon will give a certain amount of experience points to any pokemon who entered the battle while the opponent was still alive.
    >! each pokemon will have a happiness value (maximum 255). hapiness affects some pokemons ability to evolve.
    >! 11.
    >! evolution:
    >! when some pokemon reaches a certain lvl (maximum lvl 100) it will evolve. When it evolves, change sprite, change name if no nickname, add on stats, but keep evs, ivs same. Have option to not allow your pokemon to evolve.
    >! Evolutions will occur directly after the battle is finished. And will open a new window in the middle of the screen, and ask, "name is evolving, would you like "name" to evolve?".
  8. Would it be possible to have an event mid game, say, you walk into a house, and a cutscene would happen where you see a picture of like a dragon. And then there were buttons that you could click like, "run out of house", "put shield up", "attack dragon" that were clickable in this fullscreen picture.

    Actual Question:

    Which area in EA 3.0 source code would i have to modify to make an '**event**' include a **cut scene** and draw an **image** from the folder.

    And which part of the source code would I need to edit to add **clickable buttons** to the fullscreen **picture**?

    Thanks
  9. Is there someway to write an if statement into the client code to change people's NPC sprites depending on their name?

    Like:

    if playerName = "Thomas"

    sprite = 15

    end

    I'm terrible at coding if you'd noticed ![:P](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/tongue.png)
  10. I'm using eclipse advance 3.0 and when I try to make an event play an animation it doesn't run.

    Everything else in the event will work, such as speech, or choices. But when it comes time to:

    example: "animation 4, x34, y10."

    Nothing will happen at all at that pre-determined tile.

    I've read deathbeam's guide, but it doesn't touch on animations. Has anyone encountered this problem and found a solution?
  11. Hey,

    I'm having trouble understanding how animate autotiles work. I understand how to use plain autotiles, but animated ones stump me.

    I have this tileset ripped from a game and they were actually under the folder "autotileset".

    Could someone explain to me how the hell to use a 3high, 6 wide rectangle on an image like that and actually get moving water (the tile in the middle of every rectangle, making 8 tiles in total)??
  12. Could anyone explain animated tiles to me? The box is 3x6, but it only flicks through 3 (random?) squares and then repeats.

    I'm very new and appreciate any help ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)
  13. I have 2 animations (.png files), flowers and water (it's bassically 4 tiles of the same picture, except the thing in the picture moves slightly each frame).

    I want to know how to add it in my game using eclipse. what option allows this, and should I add the 4tiled picture in animations , or tilesets?

    Thanks for the help!
  14. I have a pokemon mmo, based off eclipse advanced v3.0.20.

    I need to add a pet system and have been using:

    http://www.touchofdeathforums.com/community/index.php?/topic/116108-eo-lightnings-pet-system-completely-bug-free/page__hl__pokemon__st__0

    source code.

    It needs some editing to be able to run with my program, and am needing a coder to modifiy it slightly to:

    -have the pet spawn on login

    -have the pet follow while logged in

    -have the pet depawn when logging out

    I will be able to supply both server and client files.

    will pay some money negotiated with whoever feels up for this.

    And also, if they enjoyed the work, some future projects may occur where your assisstance may be needed.

    Thanks ![:)](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/smile.png)
×
×
  • Create New...