Draken Posted November 6, 2012 Author Share Posted November 6, 2012 Most of my project fail since I do not have this feature, therefor I decided to ask if anyone could make a tutorial on how to add these to game.For those not understand what factions are, it is basically means a player can be on a "team" with certain npcs.What I personal need is the ability to make a NPC that will attack players from a different mafia family but not the player of it's family. While also leaving in a neutral NPC type that will act like the npcs normally do now.I have 3 families which are the players classes, since I do not use classes in my games. Which would require 4 factions since there is the normal neutral faction(cops/civilians/corporation guards and staff)I would guess setting a selection to select which class it would not attack in the NPC editor would be the best way and easiest.Anyways thanks for reading and hopefully helping.Keep in mind I get super confused in vb6\. More Lost then confused So much code at different locations. Link to comment Share on other sites More sharing options...
Matt Posted November 7, 2012 Share Posted November 7, 2012 Sounds simple enough. Give me a little bit of time and if it works, I'll post it on the tutorial section. Link to comment Share on other sites More sharing options...
Draken Posted November 8, 2012 Author Share Posted November 8, 2012 Alright cool deal thanks a lot. Link to comment Share on other sites More sharing options...
Richy420Rich Posted November 8, 2012 Share Posted November 8, 2012 Edit: I threw a tutorial up for what I did, if it's good to you then cool. ![:P](http://www.touchofdeathforums.com/community/public/style_emoticons/<#EMO_DIR#>/tongue.png) Link to comment Share on other sites More sharing options...
Ganjika Posted January 14, 2013 Share Posted January 14, 2013 I saw this and related posts awhile ago and responded with the below post to another thread, I wanted to post it here in hopes that it inspires more experienced folks looking to help who might just be interested in the topic of this/related posts of a Faction System:> What if instead of a class selection you had just assigned a 'Faction Group' - with a number and name associated to it (example: "1 - Citizens of Shadewillow") and these could be assigned in character editor as like a checkbox (ie: Faction Group?) and if said checkbox is clicked you could adjust which faction group via a scrollbar, where you would create/edit faction groups could either be in a new form and/or some new commands (ie: "/createfaction factionnumber" - then it could say either "Okay, Name of Faction?" or "Name Invalid/In Use" and if you enter an appropriate faction name it could say (for example) "Faction (1) 'Citizens of Shadewillow' Created!". If you wanted to go a step even futher you could make it so that npcs of rival factions attack/kill each other on site - npc's without a faction can be nutral with any other npc as they are originally without any faction add-on. The tricky part would be setting diplomatic stances between the factions (one could just create custom /commands but in terms of this it could get messy - a form might be needed, I say if any of these ideas are implemented to have all "factions" nutral unless a enemyship is declared between any two factions.> > Just some suggestions. I really dig this tutorial but i think it needs to be elaborated upon, even if it is supposed to be basic.> > In any case - Excellent work. =]> > **Edit: Below is included an example I created (it _isn't_ functional, just visual).)**> > ![](http://i1127.photobucket.com/albums/l632/EsoGuildPB/projected1_zps0ac82d6f.png)![](http://i1127.photobucket.com/albums/l632/EsoGuildPB/projected3_zps81b2e8ac.png)<- ("faction" frame as shown here - would would be in the npc editor)> > ![](http://i1127.photobucket.com/albums/l632/EsoGuildPB/proposedfaction_zps2464aae1.png)> > (^^ Faction #4 indicates how a removed faction would look on the list. if this design is ever to be used it important to make sure the> > list can still function even with the removed function - especially if said function to be removed has current engagements as an> > enemy/ally of their own/another faction(s). Link to comment Share on other sites More sharing options...
Whitepinkbun Posted January 15, 2013 Share Posted January 15, 2013 **Id do it something like this**Public Const MAX_FactionGroup As Byte = 10Public FactionGroup(1 To MAX_FactionGroup) As FactionGroupRecFactionGroupRecName as StringStatus(1 To MAX_FactionGroup) As Byte ' FactionGroup.status(1) = 1 friendly , = 2 EnemyEnd RecAdd FactionGroup to npcrecAdd faction.formAdd button to load faction.form or a /command![](http://i1127.photobucket.com/albums/l632/EsoGuildPB/projected1_zps0ac82d6f.png)![](http://i1127.photobucket.com/albums/l632/EsoGuildPB/projected3_zps81b2e8ac.png)<- ("faction" frame as shown here - would would be in the npc editor)**For this Id do the following**If FactionOriented.check = true thenFaction.Label and Faction.scroll = trueFaction.Label = FactionGroup(Faction.scroll.value).nameNpc(editor.index).Faction = Faction.Scroll![](http://i1127.photobucket.com/albums/l632/EsoGuildPB/proposedfaction_zps2464aae1.png)**With this I would have it set out more of a check box for enemy and have a list of faction groups to assign there alligence and a text box for name.**Of course you would also now have to add checks in canplayerattacknpc …. and all the other ones checking if there in the same factions and what not....Just some thoughts Hope this helps anyone.Edit : If Matthew doesn't make a tutorial about it I will. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now